Module: queue_js

Methods

(inner) _appendQueue(type, uris, play, callback) → {void}

Appends elements to the queue
Parameters:
Name Type Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
play boolean true = play added entry, false = append only
callback function callback function
Source:
Returns:
Type
void

(inner) _replaceQueue(type, uris, play, callback) → {void}

Replaces the queue with the elements
Parameters:
Name Type Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
play boolean true = play added entry, false = insert only
callback function callback function
Source:
Returns:
Type
void

(inner) appendPlayQueue(type, uris, callbackopt) → {void}

Appends an element to the queue and plays it
Parameters:
Name Type Attributes Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
callback function <optional>
callback function
Source:
Returns:
Type
void

(inner) appendQueue(type, uris, callbackopt) → {void}

Appends an element to the queue
Parameters:
Name Type Attributes Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
callback function <optional>
callback function
Source:
Returns:
Type
void

(inner) clearQueue() → {void}

Clears or crops the queue after confirmation
Source:
Returns:
Type
void

(inner) insertAfterCurrentQueue(type, uris, callbackopt) → {void}

Inserts the element after the current playing song
Parameters:
Name Type Attributes Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
callback function <optional>
callback function
Source:
Returns:
Type
void

(inner) insertPlayAfterCurrentQueue(type, uris, callbackopt) → {void}

Inserts the element after the current playing song
Parameters:
Name Type Attributes Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
callback function <optional>
callback function
Source:
Returns:
Type
void

(inner) insertQueue(type, uris, to, whence, play, callback) → {void}

Inserts elements into the queue
Parameters:
Name Type Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
to number position to insert
whence number how to interpret the to parameter: 0 = absolute, 1 = after, 2 = before current song
play boolean true = play added entry, false = insert only
callback function callback function
Source:
Returns:
Type
void

(inner) playAfterCurrent(songIds) → {void}

Plays the selected song(s) after the current song. Sets the priority if MPD is in random mode, else moves the song(s) after current playing song.
Parameters:
Name Type Description
songIds Array current playing song ids
Source:
Returns:
Type
void

(inner) queueMoveSong(from, to) → {void}

Moves a entry in the queue
Parameters:
Name Type Description
from number from position
to number to position
Source:
Returns:
Type
void

(inner) removeFromQueueIDs(ids) → {void}

Removes song ids from the queue
Parameters:
Name Type Description
ids Array MPD queue song ids
Source:
Returns:
Type
void

(inner) removeFromQueueRange(start, endopt) → {void}

Removes a song range from the queue
Parameters:
Name Type Attributes Description
start number start of the range (including)
end number <optional>
end of the range (excluding), -1 for open end
Source:
Returns:
Type
void

(inner) replacePlayQueue(type, uris, callbackopt) → {void}

Replaces the queue with the element and plays it
Parameters:
Name Type Attributes Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
callback function <optional>
callback function
Source:
Returns:
Type
void

(inner) replaceQueue(type, uris, callbackopt) → {void}

Replaces the queue with the element
Parameters:
Name Type Attributes Description
type string element type: song, dir, stream, plist, smartpls, webradio, search, album, disc, searchdir
uris Array element uris
callback function <optional>
callback function
Source:
Returns:
Type
void

(inner) resumeSong(uri, action) → {void}

Resume song API
Parameters:
Name Type Description
uri string Song uri
action string Action
Source:
Returns:
Type
void