Documentation ¶
Overview ¶
Package playout is a command line music/podcast/radio player with a text and visual view. There's support for ListenBrainz and ASCII art covers. See the player package for supported platforms, media and formats.
Index ¶
- Constants
- type PlayOptions
- type Playout
- func (p *Playout) AccessToken() string
- func (p *Playout) Code() string
- func (p *Playout) CodeToken() string
- func (p *Playout) Endpoint() string
- func (p *Playout) ListenBrainzToken() string
- func (p *Playout) MediaToken() string
- func (playout *Playout) Play(options PlayOptions) error
- func (p *Playout) RefreshToken() string
- func (p *Playout) Transport() http.RoundTripper
- func (p *Playout) UpdateAccessCode(code, access string) error
- func (p *Playout) UpdateAccessToken(value string)
- func (p *Playout) UpdateListenBrainzToken(value string) error
- func (p *Playout) UpdateTokens(access, refresh, media string) error
- func (p *Playout) UseListenBrainz() bool
- func (p *Playout) UseTrackActivity() bool
- func (p *Playout) UserAgent() string
- type SimpleView
- type Viewer
- type VisualView
Constants ¶
View Source
const ( UserAgent = "Playout/" + takeout.Version + " (" + takeout.Contact + ")" TokenAccess = "accesstoken" TokenRefresh = "refreshtoken" TokenMedia = "mediatoken" TokenCode = "codetoken" TokenListenBrainz = "lbztoken" EnableListenBrainz = "enableListenBrainz" EnableTrackActivity = "enableTrackActivity" Code = "code" Endpoint = "endpoint" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PlayOptions ¶
type Playout ¶
type Playout struct {
// contains filtered or unexported fields
}
func (*Playout) AccessToken ¶
func (*Playout) ListenBrainzToken ¶ added in v0.11.4
func (*Playout) MediaToken ¶
func (*Playout) Play ¶
func (playout *Playout) Play(options PlayOptions) error
func (*Playout) RefreshToken ¶
func (*Playout) Transport ¶ added in v0.14.0
func (p *Playout) Transport() http.RoundTripper
func (*Playout) UpdateAccessCode ¶
func (*Playout) UpdateAccessToken ¶
func (*Playout) UpdateListenBrainzToken ¶ added in v0.11.4
func (*Playout) UpdateTokens ¶
func (*Playout) UseListenBrainz ¶ added in v0.13.0
func (*Playout) UseTrackActivity ¶ added in v0.13.0
type SimpleView ¶
type SimpleView struct { }
func (SimpleView) OnStart ¶
func (SimpleView) OnStart(p *player.Player)
func (SimpleView) OnStop ¶
func (SimpleView) OnStop()
func (SimpleView) OnTrack ¶
func (SimpleView) OnTrack(p *player.Player)
type Viewer ¶
type Viewer interface { OnStart(*player.Player) OnTrack(*player.Player) OnError(*player.Player, error) OnStop() }
func NewSimpleView ¶
func NewSimpleView() Viewer
func NewVisualView ¶
func NewVisualView() Viewer
type VisualView ¶
type VisualView struct {
// contains filtered or unexported fields
}
func (*VisualView) OnStart ¶
func (v *VisualView) OnStart(p *player.Player)
func (*VisualView) OnStop ¶
func (v *VisualView) OnStop()
func (*VisualView) OnTrack ¶
func (v *VisualView) OnTrack(p *player.Player)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.