Class TrackList

java.lang.Object
  |
  +--ActiveList
        |
        +--TrackList

public class TrackList
extends ActiveList


Constructor Summary
TrackList()
          Analog to ActiveList().
TrackList(Track t)
          Analog to ActiveList(Object obj).
 
Method Summary
 Track getActiveTrack()
          Analog to getActiveObject()
 Track getTrackAt(int i)
          Analog to getObjectAt().
 java.lang.String[] getTrackNames()
          Returns an array containing all of the track names
 Track nextTrack()
          Analog to nextObject().
 Track previousTrack()
           
 Track setActiveTrack(int i)
          Analog to setActiveObject().
 Track setActiveTrackByName(java.lang.String name)
          Analog to setActiveObjectByName().
 
Methods inherited from class ActiveList
addActiveObject, addObject, containsObjectName, getActiveIndex, getActiveObject, getActiveObjectName, getObjectAt, getObjectName, getSize, nextObject, previousObject, printObjects, removeActiveObject, setActiveObject, setActiveObjectByName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TrackList

public TrackList()
Analog to ActiveList().

TrackList

public TrackList(Track t)
Analog to ActiveList(Object obj).
Parameters:
t - the track object to create the list with
Method Detail

getActiveTrack

public Track getActiveTrack()
                     throws java.lang.NoSuchFieldException
Analog to getActiveObject()
Throws:
java.lang.NoSuchFieldException - if the list is empty

setActiveTrack

public Track setActiveTrack(int i)
                     throws java.lang.ArrayIndexOutOfBoundsException
Analog to setActiveObject().
Parameters:
i - the index of the track to set as active
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the list is empty

setActiveTrackByName

public Track setActiveTrackByName(java.lang.String name)
                           throws java.lang.NoSuchFieldException
Analog to setActiveObjectByName().
Parameters:
name - the name of the track
Throws:
java.lang.NoSuchFieldException - if the track does not exist

getTrackAt

public Track getTrackAt(int i)
Analog to getObjectAt().
Parameters:
i - the index of the track

nextTrack

public Track nextTrack()
                throws java.lang.NoSuchFieldException
Analog to nextObject().
Throws:
java.lang.NoSuchFieldException - if the list is empty

previousTrack

public Track previousTrack()
                    throws java.lang.NoSuchFieldException

getTrackNames

public java.lang.String[] getTrackNames()
Returns an array containing all of the track names
Throws:
None - but it should have one - what if getSize() returns -1