net.sourceforge.atunes.kernel.handlers
Class FavoritesHandler

java.lang.Object
  extended by net.sourceforge.atunes.kernel.handlers.FavoritesHandler
All Implemented Interfaces:
ApplicationFinishListener

public class FavoritesHandler
extends java.lang.Object
implements ApplicationFinishListener

The Class FavoritesHandler.


Method Summary
 void addFavoriteAlbums(java.util.List<AudioFile> songs)
          Adds the favorite albums.
 void addFavoriteArtists(java.util.List<AudioFile> songs)
          Adds the favorite artists.
 void addFavoriteSongs(java.util.List<AudioFile> songs)
          Adds the favorite songs.
 void applicationFinish()
          Finish.
 java.lang.Runnable getAfterStartActionsRunnable()
          Returns a runnable object to be executed after application start
 java.util.Map<java.lang.String,Album> getFavoriteAlbumsInfo()
          Gets the favorite albums info.
 java.util.Map<java.lang.String,Artist> getFavoriteArtistsInfo()
          Gets the favorite artists info.
 Favorites getFavorites()
          Gets the favorites.
 java.util.List<AudioFile> getFavoriteSongs()
          Gets the favorite songs.
 java.util.Map<java.lang.String,AudioFile> getFavoriteSongsInfo()
          Gets the favorite songs info.
 java.util.Map<java.lang.String,AudioFile> getFavoriteSongsMap()
          Gets the favorite songs map
static FavoritesHandler getInstance()
          Gets the single instance of FavoritesHandler.
 java.lang.Runnable getReadFavotiresRunnable()
          Runnable process to read favorites cache.
 void removeFromFavorites(TreeObject obj)
          Removes the from favorites.
 void removeSongFromFavorites(AudioFile file)
          Removes the song from favorites.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static FavoritesHandler getInstance()
Gets the single instance of FavoritesHandler.

Returns:
single instance of FavoritesHandler

getAfterStartActionsRunnable

public java.lang.Runnable getAfterStartActionsRunnable()
Returns a runnable object to be executed after application start


addFavoriteAlbums

public void addFavoriteAlbums(java.util.List<AudioFile> songs)
Adds the favorite albums.

Parameters:
songs - the songs

addFavoriteArtists

public void addFavoriteArtists(java.util.List<AudioFile> songs)
Adds the favorite artists.

Parameters:
songs - the songs

addFavoriteSongs

public void addFavoriteSongs(java.util.List<AudioFile> songs)
Adds the favorite songs.

Parameters:
songs - the songs

applicationFinish

public void applicationFinish()
Finish.

Specified by:
applicationFinish in interface ApplicationFinishListener

getFavoriteAlbumsInfo

public java.util.Map<java.lang.String,Album> getFavoriteAlbumsInfo()
Gets the favorite albums info.

Returns:
the favorite albums info

getFavoriteArtistsInfo

public java.util.Map<java.lang.String,Artist> getFavoriteArtistsInfo()
Gets the favorite artists info.

Returns:
the favorite artists info

getFavorites

public Favorites getFavorites()
Gets the favorites.

Returns:
the favorites

getFavoriteSongs

public java.util.List<AudioFile> getFavoriteSongs()
Gets the favorite songs.

Returns:
the favorite songs

getFavoriteSongsMap

public java.util.Map<java.lang.String,AudioFile> getFavoriteSongsMap()
Gets the favorite songs map


getFavoriteSongsInfo

public java.util.Map<java.lang.String,AudioFile> getFavoriteSongsInfo()
Gets the favorite songs info.

Returns:
the favorite songs info

getReadFavotiresRunnable

public java.lang.Runnable getReadFavotiresRunnable()
Runnable process to read favorites cache.

Returns:
the read favotires runnable

removeFromFavorites

public void removeFromFavorites(TreeObject obj)
Removes the from favorites.

Parameters:
obj - the obj

removeSongFromFavorites

public void removeSongFromFavorites(AudioFile file)
Removes the song from favorites.

Parameters:
file - the file


Copyright © 2006-2008 The aTunes Team. All Rights Reserved.