StateInterface
extends
TrackInterface
in
Representation of the current state of a controller.
Table of Contents
Methods
- __construct() : mixed
- createFromXml() : TrackInterface
- getAlbum() : string
- Get the name of the album of the track.
- getAlbumArt() : string
- Get the full path to the album art for this track.
- getArtist() : string
- Get the name of the artist of the track.
- getDuration() : TimeInterface
- Get the duration of the currently active track.
- getMetaData() : string
- Get the metadata xml for this object.
- getNumber() : int
- Get the track number.
- getPosition() : TimeInterface
- Get the position of the currently active track.
- getStream() : TrackInterface|null
- Get the stream object in use (or null if we are not on a stream).
- getTitle() : string
- Get the name of the track.
- getUri() : string
- Get the URI for this object.
- isStreaming() : bool
- Check if this state is currently playing a stream.
- setAlbum() : TrackInterface
- Set the album of the track.
- setAlbumArt() : TrackInterface
- Set the album art of the track.
- setArtist() : TrackInterface
- Set the artist of the track.
- setDuration() : StateInterface
- Set the duration of the currently active track.
- setNumber() : TrackInterface
- Set the number of the track.
- setPosition() : StateInterface
- Set the position of the currently active track.
- setStream() : StateInterface
- Set the stream object in use.
- setTitle() : TrackInterface
- Set the name of the track.
Methods
__construct()
public
__construct(string $uri) : mixed
Parameters
- $uri : string
createFromXml()
public
static createFromXml(ElementInterface $xml, ControllerInterface $controller) : TrackInterface
Parameters
- $xml : ElementInterface
- $controller : ControllerInterface
Return values
TrackInterfacegetAlbum()
Get the name of the album of the track.
public
getAlbum() : string
Return values
stringgetAlbumArt()
Get the full path to the album art for this track.
public
getAlbumArt() : string
Return values
stringgetArtist()
Get the name of the artist of the track.
public
getArtist() : string
Return values
stringgetDuration()
Get the duration of the currently active track.
public
getDuration() : TimeInterface
Return values
TimeInterfacegetMetaData()
Get the metadata xml for this object.
public
getMetaData() : string
Return values
stringgetNumber()
Get the track number.
public
getNumber() : int
Return values
intgetPosition()
Get the position of the currently active track.
public
getPosition() : TimeInterface
Return values
TimeInterfacegetStream()
Get the stream object in use (or null if we are not on a stream).
public
getStream() : TrackInterface|null
Return values
TrackInterface|nullgetTitle()
Get the name of the track.
public
getTitle() : string
Return values
stringgetUri()
Get the URI for this object.
public
getUri() : string
Return values
stringisStreaming()
Check if this state is currently playing a stream.
public
isStreaming() : bool
Return values
boolsetAlbum()
Set the album of the track.
public
setAlbum(string $album) : TrackInterface
Parameters
- $album : string
Return values
TrackInterfacesetAlbumArt()
Set the album art of the track.
public
setAlbumArt(string $albumArt) : TrackInterface
Parameters
- $albumArt : string
Return values
TrackInterfacesetArtist()
Set the artist of the track.
public
setArtist(string $artist) : TrackInterface
Parameters
- $artist : string
Return values
TrackInterfacesetDuration()
Set the duration of the currently active track.
public
setDuration(TimeInterface $duration) : StateInterface
Parameters
- $duration : TimeInterface
Return values
StateInterfacesetNumber()
Set the number of the track.
public
setNumber(int $number) : TrackInterface
Parameters
- $number : int
Return values
TrackInterfacesetPosition()
Set the position of the currently active track.
public
setPosition(TimeInterface $position) : StateInterface
Parameters
- $position : TimeInterface
Return values
StateInterfacesetStream()
Set the stream object in use.
public
setStream(Stream $stream) : StateInterface
Parameters
- $stream : Stream
Return values
StateInterfacesetTitle()
Set the name of the track.
public
setTitle(string $title) : TrackInterface
Parameters
- $title : string