ocarina/include/core/playlist.h

56 lines
1.5 KiB
C++

/**
* Copyright 2013 (c) Anna Schumaker.
*
* The playlist manager is in charge of the various playlists Ocarina
* knows about. This code also manages a special queue used by the GUI
* to display the tracks in each playlist.
*
* Currently supported playlists are:
*
* Name | Description
* -------------|------------
* Banned | Songs that the user doesn't like.
* Favorites | Songs that the user likes.
* Unplayed | Songs that have not been played yet.
* Most Played | Songs with an above average play count.
* Least Played | Songs with a below average play count.
*/
#ifndef OCARINA_CORE_PLAYLIST_H
#define OCARINA_CORE_PLAYLIST_H
extern "C" {
#include <core/containers/index.h>
#include <core/queue.h>
}
#include <string>
/* Called to initialize the playlist manager. */
void playlist_init(struct queue_ops *);
/* Called to deinitialize the playlist manager. */
void playlist_deinit();
/* Called to remove banned tracks from the collection queue. */
void playlist_fixup_collection();
/* Called to add a track to a playlist. */
void playlist_add(const gchar *, struct track *);
/* Called to remove a track from a playlist. */
void playlist_remove(const gchar *, struct track *);
/* Called to check if a specific track is in the playlist. */
bool playlist_has(const gchar *, struct track *);
/* Called to fill the queue with a specific playlist. */
void playlist_select(const gchar *);
/* Called to access the playlist queue. */
struct queue *playlist_get_queue();
#endif /* OCARINA_CORE_PLAYLIST_H */