bbc.rd.tvanytime.segmentInformation
Class SegmentList

java.lang.Object
  extended by bbc.rd.tvanytime.segmentInformation.SegmentList
All Implemented Interfaces:
java.lang.Cloneable

public class SegmentList
extends java.lang.Object
implements java.lang.Cloneable

SegmentList: Represents a list of segments

Version:
1.0
Author:
Tim Sargeant, BBC Research & Development, April 2002

Constructor Summary
SegmentList()
          Constructor for objects of class SegmentList
SegmentList(SegmentInformation segInfo)
          Constructor for objects of class SegmentList with required fields
 
Method Summary
 void addSegmentInformation(SegmentInformation segInfo)
          addSegmentInformation - adds a SegmentInformation object
 java.lang.Object clone()
          Clones itself.
 int getNumSegmentInformations()
          getNumSegmentInformations - gets the number of SegmentInformation objects belonging to this SegmentList
 SegmentInformation getSegmentInformation(int index)
          getSegmentInformations - gets the SegmentInformation objects specified by index
 SegmentInformation getSegmentInformation(java.lang.String segID)
          getSegmentInformation - gets the SegmentInformation object for specified segID.
 void removeAll()
          removeAll - removes all SegmentInformation objects
 java.lang.String toString()
          Returns string representation of this object.
 java.lang.String toString(int indent)
          Returns string representation of this object.
 java.lang.String toXML()
          Returns XML representation of this table.
 java.lang.String toXML(int indent)
          Returns XML representation of this table.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SegmentList

public SegmentList()
Constructor for objects of class SegmentList


SegmentList

public SegmentList(SegmentInformation segInfo)
Constructor for objects of class SegmentList with required fields

Parameters:
segInfo - a SegmentInformation object
Method Detail

getNumSegmentInformations

public int getNumSegmentInformations()
getNumSegmentInformations - gets the number of SegmentInformation objects belonging to this SegmentList

Returns:
the number of SegmentInformation objects in this SegmentList

getSegmentInformation

public SegmentInformation getSegmentInformation(int index)
getSegmentInformations - gets the SegmentInformation objects specified by index

Parameters:
index - the index to the SegmentInformation object
Returns:
the SegmentInformation object

getSegmentInformation

public SegmentInformation getSegmentInformation(java.lang.String segID)
getSegmentInformation - gets the SegmentInformation object for specified segID. Returns 'null' if no match

Parameters:
segID - the segID
Returns:
the SegmentInformation object

addSegmentInformation

public void addSegmentInformation(SegmentInformation segInfo)
addSegmentInformation - adds a SegmentInformation object

Parameters:
segInfo - the SegmentInformation object

removeAll

public void removeAll()
removeAll - removes all SegmentInformation objects


toXML

public java.lang.String toXML()
Returns XML representation of this table.

Returns:
XML representation of this table.

toXML

public java.lang.String toXML(int indent)
Returns XML representation of this table.

Parameters:
indent - Number of tabs with which to indent the string.
Returns:
XML representation of the table.

toString

public java.lang.String toString()
Returns string representation of this object.

Overrides:
toString in class java.lang.Object
Returns:
string representation of this object.

toString

public java.lang.String toString(int indent)
Returns string representation of this object.

Parameters:
indent - number of tabs to put before the string.
Returns:
string representation of this object.

clone

public java.lang.Object clone()
Clones itself.

Overrides:
clone in class java.lang.Object
Returns:
A copy of itself.