pub enum Command {
Quit,
Library(LibraryCommand),
EventStream,
Disconnect,
Playback(PlaybackCommand),
Ping,
CanRaise,
Raise,
CanSetFullscreen,
SetFullscreen(bool),
CanQuit,
}Expand description
Command that can be executed by a daemon instance.
The expected response may be different depending on the command sent. If it isn’t specified in
the variant documentation, assume Response::Ok is the expected response.
Variants§
Quit
Stop the daemon instance.
After sending this command, the daemon will close almost immediately, so all connections to it should be considered closed.
Library(LibraryCommand)
Subcommand for managing the music library.
EventStream
Stream events from the daemon.
The daemon will stop accepting requests from the connection this command was executed on.
This command may fail if initial events cannot be obtained (eg. the music library is not initialized or the queue state is not ready). The daemon will never return an incomplete set of initial events if some cannot be obtained.
Disconnect
Close the connection to the daemon.
Playback(PlaybackCommand)
Command to the playback module.
Ping
Ping the daemon.
The daemon will respond to this with Response::Pong if successful.
CanRaise
Check if the daemon can raise.
Raise
Request the daemon to raise.
CanSetFullscreen
Check if clients can toggle fullscreen mode on daemon’s user interface.
SetFullscreen(bool)
Toggle fullscreen mode for the daemon’s user interface.
CanQuit
Check if the daemon accepts quit requests from clients.