Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Lavalink ¶
type Lavalink struct { // Client is the Lavalink client. Client disgolink.Client // Queues is the Lavalink queues. Queues *LavalinkQueueManager }
Lavalink contains the Lavalink client and the queues.
type LavalinkNodes ¶
type LavalinkNodes struct {
Nodes []disgolink.NodeConfig `json:"nodes"`
}
LavalinkNodes contains the Lavalink nodes.
type LavalinkQueue ¶
type LavalinkQueue struct { // Tracks is the tracks in the queue. Tracks []lavalink.Track // Type is the type of the queue. Type LavalinkQueueType }
LavalinkQueue contains the Lavalink queue.
func (*LavalinkQueue) Add ¶
func (q *LavalinkQueue) Add(track ...lavalink.Track)
Add adds tracks to the queue.
func (*LavalinkQueue) Next ¶
func (q *LavalinkQueue) Next() (lavalink.Track, bool)
Next returns the next track in the queue.
func (*LavalinkQueue) Shuffle ¶
func (q *LavalinkQueue) Shuffle()
Shuffle shuffles the tracks in the queue.
type LavalinkQueueManager ¶
type LavalinkQueueManager struct {
Queues map[snowflake.ID]*LavalinkQueue
}
LavalinkQueueManager contains the Lavalink queues.
func (*LavalinkQueueManager) Delete ¶
func (q *LavalinkQueueManager) Delete(guildID snowflake.ID)
Delete deletes the Lavalink queue for the specified guild.
func (*LavalinkQueueManager) Get ¶
func (q *LavalinkQueueManager) Get(guildID snowflake.ID) *LavalinkQueue
Get returns the Lavalink queue for the specified guild.
type LavalinkQueueType ¶
type LavalinkQueueType string
LavalinkQueueType is the type of the Lavalink queue.
const ( // LavalinkQueueTypeNormal is the normal queue type. LavalinkQueueTypeNormal LavalinkQueueType = "normal" // LavalinkQueueTypeRepeatTrack is the repeat track queue type. LavalinkQueueTypeRepeatTrack LavalinkQueueType = "repeat_track" // LavalinkQueueTypeRepeatQueue is the repeat queue queue type. LavalinkQueueTypeRepeatQueue LavalinkQueueType = "repeat_queue" )
func (LavalinkQueueType) String ¶
func (q LavalinkQueueType) String() string
String returns the string representation of the LavalinkQueueType.
Click to show internal directories.
Click to hide internal directories.