|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--com.neoworks.jukex.sqlimpl.JukeXTrackStore
The JukeXTrackStore using a MySQL back end. This is where all core objects should be obtained from.
| Field Summary | |
static java.lang.String |
DB_NAME
Name of the database to use |
| Method Summary | |
Attribute |
createAttribute(java.lang.String name,
int type)
Create a new attribute for data to support in the jukebox schema |
Playlist |
createPlaylist(java.lang.String name)
Create a playlist with the specified name |
java.util.Collection |
getAllPlaylists()
Return all of the Playlists currently defined |
Attribute |
getAttribute(java.lang.String name)
Return the Attribute object representing the attribute with that name |
java.util.Set |
getAttributes()
Get a list of all the attributes currently supported by the system |
BatchTrackLoader |
getBatchTrackLoader()
Return a batch track loader |
java.lang.String |
getDBName()
Get the name of the database the TrackStore is using |
static TrackStore |
getInstance()
Get an instance of the TrackStore |
Playlist |
getPlaylist(java.lang.String name)
Get the Playlist with the specified name |
Track |
getTrack(long id)
Get a track from the database by database id |
Track |
getTrack(java.net.URL url)
Get a track from the database by URL |
long |
getTrackCount()
Get the total track count |
long[] |
getTrackIds()
Get an array containing the ids of the tracks in the Track database |
java.util.List |
getTracks(java.util.List ids)
Get a List of Tracks corresponding to a list of database ids |
java.util.List |
getTracks(long[] ids)
Retrieve a List of Track objects with ids as
specified in the passed array |
void |
initialise()
Initialise track store |
Track |
storeTrack(java.net.URL url,
java.util.Date modifiedTime)
Create a track in the database with the specified url and return the object representing that track. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String DB_NAME
| Method Detail |
public static TrackStore getInstance()
public void initialise()
public long getTrackCount()
getTrackCount in interface TrackStorepublic Track getTrack(java.net.URL url)
getTrack in interface TrackStoreurl - The URL of the track
public Track getTrack(long id)
getTrack in interface TrackStoreid - The id of the track
public java.util.List getTracks(long[] ids)
List of Track objects with ids as
specified in the passed array
getTracks in interface TrackStoreids - The array of ids of Tracks to retrieve
List of Track objectspublic java.util.List getTracks(java.util.List ids)
getTracks in interface TrackStoreids - A List of database track ids
public Track storeTrack(java.net.URL url,
java.util.Date modifiedTime)
TrackStore
storeTrack in interface TrackStoreurl - The URL of the track to be added to the databasemodifiedTime - The date that this Track entry was modified
public Attribute getAttribute(java.lang.String name)
TrackStore
getAttribute in interface TrackStoreAttribute object representing the name passed, or null, if it is not found.public java.util.Set getAttributes()
getAttributes in interface TrackStoreSet of all Attribute objects
currently available in the database.
public Attribute createAttribute(java.lang.String name,
int type)
throws java.lang.Exception
createAttribute in interface TrackStorename - The name of the Attributetype - The type of the Attribute
java.lang.Exceptionpublic java.lang.String getDBName()
public long[] getTrackIds()
TrackStore
getTrackIds in interface TrackStorepublic Playlist getPlaylist(java.lang.String name)
getPlaylist in interface TrackStorename - The name of the playlist required
public Playlist createPlaylist(java.lang.String name)
createPlaylist in interface TrackStorepublic java.util.Collection getAllPlaylists()
TrackStore
getAllPlaylists in interface TrackStorepublic BatchTrackLoader getBatchTrackLoader()
getBatchTrackLoader in interface TrackStore
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||