service

package
v1.0.12 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2022 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service interface {
	Run() error
	Stop() error

	RegisterReadyHandler(func(*discordgo.Session, *discordgo.Ready))
	RegisterMessageHandler(func(*discordgo.Session, *discordgo.MessageCreate))

	GetGuildByChannelID(ctx context.Context, channelID string) (*discordgo.Guild, error)

	InitVoice(guildID string)

	HandlePing(ctx context.Context, m *discordgo.MessageCreate) error
	HandleHelp(ctx context.Context, m *discordgo.MessageCreate) error
	HandlePrompt(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild, content string) error
	HandlePlay(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild, args []string) error
	HandleJoin(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild) error
	HandleLeave(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild) error
	HandlePause(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild) error
	HandleResume(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild) error
	HandleStop(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild) error
	HandleNext(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild) error
	HandlePrev(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild) error
	HandleJump(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild, args []string) error
	HandleQueue(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild, args []string) error
	HandleRemove(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild, args []string) error
	HandlePurge(ctx context.Context, m *discordgo.MessageCreate, g *discordgo.Guild) error
}

Service contains functions for service.

func New

New to create new service.

Jump to

Keyboard shortcuts

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