Documentation
¶
Index ¶
- type BackendPlayer
- type Player
- func (p *Player) AvailablePlayerTypes() []config.PlayerType
- func (p *Player) Close() error
- func (p *Player) Metadata() *model.Metadata
- func (p *Player) Pause(value bool) error
- func (p *Player) Play(url string) error
- func (p *Player) Seek(amtSec int) *model.Metadata
- func (p *Player) SetVolume(value int) (int, error)
- func (p *Player) Stop() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BackendPlayer ¶ added in v0.8.13
type BackendPlayer interface {
Play(url string) error
Pause(value bool) error
Stop() error
// SetVolume:
//
// - sets the volume to an absolute value in [0,100]
// - returns the set value and nil if succeeded, error if failed
SetVolume(value int) (int, error)
Metadata() *model.Metadata
// Seek:
//
// - seek by a +/- amount of seconds,
// - returns the metadata for the new playback position if succeeded, metadata with error if failed
Seek(amtSec int) *model.Metadata
Close() error
}
type Player ¶
type Player struct {
// contains filtered or unexported fields
}
func (*Player) AvailablePlayerTypes ¶ added in v0.8.0
func (p *Player) AvailablePlayerTypes() []config.PlayerType
func (*Player) Seek ¶ added in v0.3.4
Seek:
- seek by a +/- amount of seconds,
- returns the metadata for the new playback position if succeeded, metadata with error if failed
Click to show internal directories.
Click to hide internal directories.