Documentation
¶
Index ¶
- type DebugPlayerInfo
- type DebugStatus
- type MPRISPlugin
- func (p *MPRISPlugin) DebugStatus() *DebugStatus
- func (p *MPRISPlugin) Handle(ctx context.Context, dev device.Sender, pkt *protocol.Packet) error
- func (p *MPRISPlugin) IncomingTypes() []string
- func (p *MPRISPlugin) Name() string
- func (p *MPRISPlugin) OnConnect(dev device.Sender)
- func (p *MPRISPlugin) OnDisconnect(dev device.Sender)
- func (p *MPRISPlugin) OutgoingTypes() []string
- func (p *MPRISPlugin) Timeout() time.Duration
- type MPRISRequest
- type NowPlaying
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DebugPlayerInfo ¶ added in v1.10.0
type DebugPlayerInfo struct {
DisplayName string `json:"displayName"`
BusName string `json:"busName"`
ShortName string `json:"shortName"`
Title string `json:"title"`
Artist string `json:"artist"`
Album string `json:"album"`
PlaybackStatus string `json:"playbackStatus"`
IsPlaying bool `json:"isPlaying"`
Volume int `json:"volume"`
Pos int64 `json:"pos"`
Length int64 `json:"length"`
AlbumArtUrl string `json:"albumArtUrl"`
CanSeek bool `json:"canSeek"`
CanGoNext bool `json:"canGoNext"`
CanGoPrevious bool `json:"canGoPrevious"`
CanPlay bool `json:"canPlay"`
CanPause bool `json:"canPause"`
Error string `json:"error,omitempty"`
}
type DebugStatus ¶ added in v1.10.0
type DebugStatus struct {
WatcherRunning bool `json:"watcherRunning"`
DeviceCount int `json:"deviceCount"`
Players []DebugPlayerInfo `json:"players"`
PlayerMappings map[string]string `json:"playerMappings"`
}
type MPRISPlugin ¶
type MPRISPlugin struct {
// contains filtered or unexported fields
}
func NewMPRISPlugin ¶
func NewMPRISPlugin(tlsConfig *tls.Config, logger *zap.Logger) *MPRISPlugin
func (*MPRISPlugin) DebugStatus ¶ added in v1.10.0
func (p *MPRISPlugin) DebugStatus() *DebugStatus
func (*MPRISPlugin) IncomingTypes ¶
func (p *MPRISPlugin) IncomingTypes() []string
func (*MPRISPlugin) Name ¶
func (p *MPRISPlugin) Name() string
func (*MPRISPlugin) OnConnect ¶
func (p *MPRISPlugin) OnConnect(dev device.Sender)
func (*MPRISPlugin) OnDisconnect ¶
func (p *MPRISPlugin) OnDisconnect(dev device.Sender)
func (*MPRISPlugin) OutgoingTypes ¶
func (p *MPRISPlugin) OutgoingTypes() []string
func (*MPRISPlugin) Timeout ¶
func (p *MPRISPlugin) Timeout() time.Duration
type MPRISRequest ¶
type MPRISRequest struct {
RequestPlayerList bool `json:"requestPlayerList,omitempty"`
RequestNowPlaying bool `json:"requestNowPlaying,omitempty"`
RequestVolume bool `json:"requestVolume,omitempty"`
Player string `json:"player,omitempty"`
Action string `json:"action,omitempty"`
SetVolume *int `json:"setVolume,omitempty"`
Seek *int64 `json:"Seek,omitempty"`
SetPosition *int64 `json:"SetPosition,omitempty"`
SetShuffle *bool `json:"setShuffle,omitempty"`
SetLoopStatus string `json:"setLoopStatus,omitempty"`
AlbumArtUrl string `json:"albumArtUrl,omitempty"`
}
type NowPlaying ¶
type NowPlaying struct {
Player string `json:"player"`
Title string `json:"title"`
Artist string `json:"artist"`
Album string `json:"album"`
AlbumArtUrl string `json:"albumArtUrl"`
Url string `json:"url,omitempty"`
Length int64 `json:"length"`
Pos int64 `json:"pos,omitempty"`
IsPlaying bool `json:"isPlaying"`
Volume int `json:"volume,omitempty"`
CanControl bool `json:"canControl"`
CanGoNext bool `json:"canGoNext"`
CanGoPrevious bool `json:"canGoPrevious"`
CanPause bool `json:"canPause"`
CanPlay bool `json:"canPlay"`
CanSeek bool `json:"canSeek"`
PlaybackStatus string `json:"playbackStatus"`
Shuffle *bool `json:"shuffle,omitempty"`
LoopStatus string `json:"loopStatus,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.