net.sf.freecol.client.gui.sound
Class SoundLibrary
java.lang.Object
net.sf.freecol.client.gui.sound.SoundLibrary
- Direct Known Subclasses:
- MusicLibrary, SfxLibrary
public class SoundLibrary
- extends java.lang.Object
A SoundLibrary stores a number of playlists.
|
Constructor Summary |
SoundLibrary(java.io.File dir)
The constructor. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
playlists
private java.util.Map<java.lang.String,Playlist> playlists
- This array contains the playlists.
soundFileFilter
private static final java.io.FileFilter soundFileFilter
SoundLibrary
public SoundLibrary(java.io.File dir)
throws FreeColException
- The constructor. Load the directory spesified by file.
- Parameters:
dir - A directory containing the sound-files.
- Throws:
FreeColException - If the file spesified is not a directory.
get
public Playlist get(java.lang.String string)
- Returns a playlist associated with a
Nation.
- Parameters:
string - The key to look up a Playlist.
- Returns:
- The
PlayList specified by the ID.
get
public Playlist get(SoundLibrary.SoundEffect effect)
- Returns a playlist identified by id.
- Parameters:
effect - The sound effect.
- Returns:
- The
Playlist specified by the ID.