db

package
v0.0.0-...-f0d4de4 Latest Latest
Warning

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

Go to latest
Published: Jul 8, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(cfg Config, s SimStoreWithDB) error

Types

type Bot

type Bot struct {
	Log   *zap.SugaredLogger
	Store SimStoreWithDB
	// contains filtered or unexported fields
}

func (*Bot) Approve

func (b *Bot) Approve(s *discordgo.Session, m *discordgo.MessageCreate)

func (*Bot) DBList

func (b *Bot) DBList(s *discordgo.Session, m *discordgo.MessageCreate)

func (*Bot) Delete

func (b *Bot) Delete(s *discordgo.Session, m *discordgo.MessageCreate)

func (*Bot) Help

func (b *Bot) Help(s *discordgo.Session, m *discordgo.MessageCreate)

func (*Bot) List

func (b *Bot) List(s *discordgo.Session, m *discordgo.MessageCreate)

func (*Bot) Reject

func (b *Bot) Reject(s *discordgo.Session, m *discordgo.MessageCreate)

func (*Bot) Replace

func (b *Bot) Replace(s *discordgo.Session, m *discordgo.MessageCreate)

func (*Bot) ShowConfig

func (b *Bot) ShowConfig(s *discordgo.Session, m *discordgo.MessageCreate)

func (*Bot) Submit

func (b *Bot) Submit(s *discordgo.Session, m *discordgo.MessageCreate)

type Config

type Config struct {
	Token          string
	AdminChannelID string //id for the admin channel
	DBPath         string
}

type SimStoreWithDB

type SimStoreWithDB interface {
	store.SimStore
	store.SimDBStore
}

Jump to

Keyboard shortcuts

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