javazoom.jlgui.player.amp.playlist
Interface Playlist
- BasePlaylist
public interface Playlist
Playlist.
This interface defines method that a playlist should implement.
A playlist provides a collection of item to play and a cursor to know
which item is playing.
addItemAt
public void addItemAt(PlaylistItem pli,
int pos)
Adds item at a given position in the playlist.
appendItem
public void appendItem(PlaylistItem pli)
Append item at the end of the playlist.
begin
public void begin()
Moves the cursor at the begining of the Playlist.
getAllItems
public Collection getAllItems()
Returns a collection of playlist items.
getCursor
public PlaylistItem getCursor()
Returns item matching to the cursor.
getIndex
public int getIndex(PlaylistItem pli)
Returns index of playlist item.
getItemAt
public PlaylistItem getItemAt(int pos)
Returns item at a given position from the playlist.
getPlaylistSize
public int getPlaylistSize()
Returns then number of items in the playlist.
getSelectedIndex
public int getSelectedIndex()
Returns item matching to the cursor.
isModified
public boolean isModified()
Checks the modification flag
load
public boolean load(String filename)
Loads playlist.
nextCursor
public void nextCursor()
Computes cursor position (next).
previousCursor
public void previousCursor()
Computes cursor position (previous).
removeAllItems
public void removeAllItems()
Removes all items in the playlist.
removeItem
public void removeItem(PlaylistItem pli)
Searchs and removes item from the playlist.
removeItemAt
public void removeItemAt(int pos)
Removes item at a given position from the playlist.
save
public boolean save(String filename)
Saves playlist.
setCursor
public void setCursor(int index)
setModified
public boolean setModified(boolean set)
Set the modification flag for the playlist
shuffle
public void shuffle()
Randomly re-arranges the playlist.
sortItems
public void sortItems(int sortmode)
Sorts items of the playlist.
JavaZOOM 1999-2006