Documentation ¶
Index ¶
- type Message
- type NodeMessage
- func (m NodeMessage) Binary(r channel.BinaryWriter) error
- func (m NodeMessage) Equal(msg channel.Msg) bool
- func (m NodeMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
- func (m NodeMessage) FromJSON(r io.Reader) (channel.Msg, io.Reader, error)
- func (m NodeMessage) JSON(w io.Writer) error
- type ServerMessage
- func (m ServerMessage) Binary(w channel.BinaryWriter) error
- func (m ServerMessage) Equal(msg channel.Msg) bool
- func (m ServerMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
- func (m ServerMessage) FromJSON(r io.Reader) (channel.Msg, io.Reader, error)
- func (m ServerMessage) JSON(w io.Writer) error
- type ServerPlaylistMessage
- func (m ServerPlaylistMessage) Binary(w channel.BinaryWriter) error
- func (m ServerPlaylistMessage) Equal(msg channel.Msg) bool
- func (m ServerPlaylistMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
- func (m ServerPlaylistMessage) FromJSON(r io.Reader) (channel.Msg, io.Reader, error)
- func (m ServerPlaylistMessage) JSON(w io.Writer) error
- type ServerSongMessage
- type ServerStateMessage
- func (m ServerStateMessage) Binary(w channel.BinaryWriter) error
- func (m ServerStateMessage) Equal(msg channel.Msg) bool
- func (m ServerStateMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
- func (m ServerStateMessage) FromJSON(r io.Reader) (channel.Msg, io.Reader, error)
- func (m ServerStateMessage) JSON(w io.Writer) error
- type Song
- type SongDataMessage
- func (m SongDataMessage) Binary(w channel.BinaryWriter) error
- func (m SongDataMessage) Close() error
- func (m SongDataMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
- func (m SongDataMessage) FromJSON(r io.Reader) (channel.Msg, io.Reader, error)
- func (m SongDataMessage) JSON(w io.Writer) error
- func (m SongDataMessage) Upload() io.Reader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Message ¶
type Message struct { Command string `json:"cmd"` channel.NeverEqual channel.NoClose }
func BinaryMessage ¶
func BinaryMessage(r channel.BinaryReader) (Message, error)
func (Message) FromBinary ¶
type NodeMessage ¶
func BinaryNodeMessage ¶
func BinaryNodeMessage(r channel.BinaryReader) (NodeMessage, error)
func JSONNodeMessage ¶
func (NodeMessage) Binary ¶
func (m NodeMessage) Binary(r channel.BinaryWriter) error
func (NodeMessage) FromBinary ¶
func (m NodeMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
type ServerMessage ¶
type ServerMessage struct { View byte `json:"view"` Title string `json:"title"` Text string `json:"text"` Songs []Song `json:"songs"` channel.NoClose }
func BinaryServerMessage ¶
func BinaryServerMessage(r channel.BinaryReader) (ServerMessage, error)
func JSONServerMessage ¶
func (ServerMessage) Binary ¶
func (m ServerMessage) Binary(w channel.BinaryWriter) error
func (ServerMessage) FromBinary ¶
func (m ServerMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
type ServerPlaylistMessage ¶
func BinaryServerPlaylistMessage ¶
func BinaryServerPlaylistMessage(r channel.BinaryReader) (ServerPlaylistMessage, error)
func (ServerPlaylistMessage) Binary ¶
func (m ServerPlaylistMessage) Binary(w channel.BinaryWriter) error
func (ServerPlaylistMessage) FromBinary ¶
func (m ServerPlaylistMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
type ServerSongMessage ¶
func BinaryServerSongMessage ¶
func BinaryServerSongMessage(r channel.BinaryReader) (ServerSongMessage, error)
func JSONServerSongMessage ¶
func (ServerSongMessage) FromBinary ¶
func (m ServerSongMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
type ServerStateMessage ¶
type ServerStateMessage struct { Paused bool `json:"paused"` Position time.Duration `json:"position"` Duration time.Duration `json:"duration"` Volume float64 `json:"volume"` channel.NoClose }
func BinaryServerStateMessage ¶
func BinaryServerStateMessage(r channel.BinaryReader) (ServerStateMessage, error)
func JSONServerStateMessage ¶
func (ServerStateMessage) Binary ¶
func (m ServerStateMessage) Binary(w channel.BinaryWriter) error
func (ServerStateMessage) FromBinary ¶
func (m ServerStateMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
type Song ¶
type Song struct { P_NS string `json:"ns"` P_ID string `json:"id"` P_Title string `json:"title"` Active bool `json:"a"` Problem string `json:"problem"` }
func BinarySong ¶
func BinarySong(r channel.BinaryReader) (Song, error)
type SongDataMessage ¶
type SongDataMessage struct { Available bool Song Song Size int64 channel.NeverEqual // contains filtered or unexported fields }
func BinarySongDataMessage ¶
func BinarySongDataMessage(r channel.BinaryReader) (SongDataMessage, error)
func JSONSongDataMessage ¶
func NewNoSongDataMessage ¶
func NewNoSongDataMessage() SongDataMessage
func NewSongDataMessage ¶
func NewSongDataMessage(song Song, size int64, r io.Reader) SongDataMessage
func (SongDataMessage) Binary ¶
func (m SongDataMessage) Binary(w channel.BinaryWriter) error
func (SongDataMessage) Close ¶
func (m SongDataMessage) Close() error
func (SongDataMessage) FromBinary ¶
func (m SongDataMessage) FromBinary(r channel.BinaryReader) (channel.Msg, error)
func (SongDataMessage) Upload ¶
func (m SongDataMessage) Upload() io.Reader
Click to show internal directories.
Click to hide internal directories.