paracusia v0.2.11 Paracusia.MpdClient.Playlists

Functions related to stored playlists.

See also: https://musicpd.org/doc/protocol/playlist_files.html

Link to this section Summary

Functions

Adds uri to the playlist playlist.m3u

Clears the playlist playlist.m3u

Deletes the song at position pos from the playlist

Returns a list containing all songs in the given playlist

Returns a list of all playlists inside the playlists directory

Returns a map containing all songs from the playlist and their metadata

Loads the playlist into the queue

Loads a given range from the playlist into the queue

Moves the song at position from in the playlist playlist.m3u to the position to

Removes the playlist playlist.m3u from the playlist directory

Renames the playlist playlist.m3u to new_name.m3u

Saves the current playlist to name.m3u in the playlist directory

Link to this section Functions

Adds uri to the playlist playlist.m3u

playlist.m3u will be created if it does not already exist.

Clears the playlist playlist.m3u

Link to this function

delete_pos(playlist, pos)
delete_pos(String.t(), integer()) :: :ok | Paracusia.MpdTypes.mpd_error()

Deletes the song at position pos from the playlist.

Returns a list containing all songs in the given playlist.

Link to this function

list_all()
list_all() :: {:ok, [map()]} | Paracusia.MpdTypes.mpd_error()

Returns a list of all playlists inside the playlists directory.

Link to this function

list_info(playlist)
list_info(String.t()) :: {:ok, [map()]} | Paracusia.MpdTypes.mpd_error()

Returns a map containing all songs from the playlist and their metadata.

Loads the playlist into the queue.

Loads a given range from the playlist into the queue.

Link to this function

move(playlist, from, to)

Moves the song at position from in the playlist playlist.m3u to the position to.

Link to this function

remove(playlist)
remove(String.t()) :: :ok | Paracusia.MpdTypes.mpd_error()

Removes the playlist playlist.m3u from the playlist directory.

Link to this function

rename(playlist, new_name)

Renames the playlist playlist.m3u to new_name.m3u

Saves the current playlist to name.m3u in the playlist directory.