Package sidplay.player
Klasse PlayList
java.lang.Object
sidplay.player.PlayList
PlayList is a track list of songs to play. It starts with the first entry,
which is the marker to detect a wrap-around. The current entry is the
currently selected song.
E.g. 5 songs in a tune using start song number 3 will result in
[3],4,5,1,2 -> first = 3, length=5, current song is within range 1..5
E.g. 5 songs in a tune using start song number 3 will result in
[3],4,5,1,2 -> first = 3, length=5, current song is within range 1..5
- Autor:
- Ken Händel
-
Feldübersicht
FelderModifizierer und TypFeldBeschreibungprivate intCurrent entry of the playlist.private final intFirst entry of the playlist.private final intNumber of entries in the playlist.private final ISidPlay2SectionConfiguration.private final SidTuneCurrent Tune. -
Konstruktorübersicht
KonstruktorenKonstruktorBeschreibungPlayList(ISidPlay2Section sidplay2Section, SidTune tune, boolean firstPlayListEntryIsOne) -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungvoidfirst()Choose the first playlist entry.intGet the currently selected playlist entry.intGet a number of entries.intgetNext()Get the next playlist entry.intGet the previous playlist entry.intGet the current track (playlist entry relative to the first).booleanhasNext()Is a next playlist entry available?booleanIs a previous playlist entry available?voidlast()Choose the last playlist entry.voidnext()Choose the next playlist entry.voidprepare()voidprevious()Choose the previous playlist entry.
-
Felddetails
-
sidplay2Section
Configuration. -
tune
Current Tune. -
first
private final int firstFirst entry of the playlist. -
length
private final int lengthNumber of entries in the playlist. -
current
private int currentCurrent entry of the playlist. It wraps around the number of entries.
-
-
Konstruktordetails
-
PlayList
-
-
Methodendetails
-
prepare
public void prepare() -
getCurrent
public int getCurrent()Get the currently selected playlist entry.- Gibt zurück:
- current song number
-
getTrackNum
public int getTrackNum()Get the current track (playlist entry relative to the first).- Gibt zurück:
- track number
-
getLength
public int getLength()Get a number of entries.- Gibt zurück:
- number of songs
-
next
public void next()Choose the next playlist entry. -
previous
public void previous()Choose the previous playlist entry. -
first
public void first()Choose the first playlist entry. -
last
public void last()Choose the last playlist entry. -
hasPrevious
public boolean hasPrevious()Is a previous playlist entry available?- Gibt zurück:
- is a previous song available?
-
hasNext
public boolean hasNext()Is a next playlist entry available?- Gibt zurück:
- is the next song available?
-
getPrevious
public int getPrevious()Get the previous playlist entry.- Gibt zurück:
- the previous song of the playlist
-
getNext
public int getNext()Get the next playlist entry.- Gibt zurück:
- the next song of the playlist
-