model

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 24, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DevicesResponse

type DevicesResponse struct {
	Devices []PlayerDevice `json:"devices"`
}

type PlayerDevice

type PlayerDevice struct {
	Name                  string `json:"name,omitempty"`
	DeviceOwnerCustomerId string `json:"deviceOwnerCustomerId"`
	DeviceType            string `json:"deviceType"`
	SerialNumber          string `json:"serialNumber"`
}

type Queue

type Queue struct {
	State         string `json:"state"`
	QueuePosition int    `json:"queuePosition"`
	TrackPosition int    `json:"trackPosition"`
	Songs         []Song `json:"queue"`
	Shuffle       bool   `json:"shuffle"`
	Repeat        bool   `json:"repeat"`
}

func NewQueue

func NewQueue() *Queue

func (*Queue) Current

func (q *Queue) Current() *Song

func (*Queue) HasItems

func (q *Queue) HasItems() bool

func (*Queue) HasNext

func (q *Queue) HasNext() bool

func (*Queue) HasPrev

func (q *Queue) HasPrev() bool

func (*Queue) Next

func (q *Queue) Next() *Song

func (*Queue) PeekNext

func (q *Queue) PeekNext() *Song

func (*Queue) Prev

func (q *Queue) Prev() *Song

type Song

type Song struct {
	Id       string `json:"id"`
	Name     string `json:"name"`
	Album    string `json:"album"`
	Artist   string `json:"artist"`
	Duration int    `json:"duration"`
	Cover    string `json:"cover"`
	Stream   string `json:"stream"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL