collection

std

A playlist or collection of songs

Extension Functions

native fun anySongMatches(fn) on collection link

Loops through all songs of the collection and checks if the condition is matched.

Params
fn

The function to check if the condition is matched. A single parameter song is passed into the function.

Returns boolean

If the condition is matched

native fun containsArtist(artist) on collection link

Checks if the collection contains any song with the given artist as the song's first artist.

Params
artist

The artist to check

Returns boolean

If the collection contains the artist

native fun getCreator() on collection link

Gets the creator of the collection.

Returns Artist

The creator of the collection

native fun getId() on collection link

Gets the ID of the collection. This is an ID identifiable by the provider which owns this collection.

Returns string

The ID of the collection

native fun getName() on collection link

Gets the name of the collection.

Returns string

The name of the collection

native fun getTrackCount() on collection link

Gets the number of tracks in the collection.

Returns int

The number of tracks

native fun getUrl() on collection link

Gets the URL of the collection.

Returns string

The URL of the collection