用java实现mp3文件播放的功能

源代码在线查看: playlist.java

软件大小: 25 K
上传用户: sun337146987
关键词: java mp3 播放
下载地址: 免注册下载 普通下载 VIP

相关代码

				package javazoom.jlGui.playlist;
				
				/**
				 * Playlist.
				 */
				
				import java.util.Collection;
				
				/**
				 * 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.
				 */
				public interface Playlist
				{
					// Next methods will be called by the Playlist UI.
				
					/**
					 * Loads playlist.
					 */
					public void load(String filename);
					/**
					 * Saves playlist.
					 */
					public void save(String filename);
					/**
					 * Adds item at a given position in the playlist.
					 */
					public void addItemAt(PlaylistItem pli, int pos);
					/**
					 * Searchs and removes item from the playlist.
					 */
					public void removeItem(PlaylistItem pli);
					/**
					 * Removes item at a given position from the playlist.
					 */
					public void removeItemAt(int pos);
					/**
					 * Append item at the end of the playlist.
					 */
					public void appendItem(PlaylistItem pli);
					/**
					 * Sorts items of the playlist.
					 */
					public void sortItems(int sortmode);
					/**
					 * Returns item at a given position from the playlist.
					 */
					public PlaylistItem getItemAt(int pos);
					/**
					 * Returns a collection of playlist items.
					 */
					public Collection getAllItems();
					/**
					 * Returns then number of items in the playlist.
					 */
					public int getPlaylistSize();
				
				    // Next methods will be used by the Player
				
					/**
					 * Randomly re-arranges the playlist.
					 */
					public void shuffle();
					/**
					 * Returns item matching to the cursor.
					 */
					public PlaylistItem getCursor();
					/**
					 * Computes cursor position (next).
					 */
					public void nextCursor();
					/**
					 * Computes cursor position (previous).
					 */
					public void previousCursor();
				}
							

相关资源