state

package
v0.0.0-...-84f1622 Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2025 License: AGPL-3.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Pool                    *pgxpool.Pool
	Rueidis                 rueidis.Client // where perf is needed
	DovewingPlatformDiscord *DiscordState
	Discord                 *discordgo.Session
	Logger                  *zap.Logger
	Context                 = context.Background()
	Validator               = validator.New()
	BotUser                 *discordgo.User
	CurrentOperationMode    string // Current mode splashtail is operating in
	Config                  *config.Config

	IpcClient       http.Client
	IpcClientHttp11 http.Client
)

Functions

func Setup

func Setup()

Types

type DiscordState

type DiscordState struct {
	// contains filtered or unexported fields
}

func (*DiscordState) GetState

func (d *DiscordState) GetState() *dovewing.BaseState

func (*DiscordState) GetUser

func (d *DiscordState) GetUser(ctx context.Context, id string) (*dovetypes.PlatformUser, error)

func (*DiscordState) Init

func (d *DiscordState) Init() error

func (*DiscordState) Initted

func (d *DiscordState) Initted() bool

func (*DiscordState) PlatformName

func (d *DiscordState) PlatformName() string

func (*DiscordState) PlatformSpecificCache

func (d *DiscordState) PlatformSpecificCache(ctx context.Context, id string) (*dovetypes.PlatformUser, error)

func (*DiscordState) ValidateId

func (d *DiscordState) ValidateId(id string) (string, error)

type DiscordStateConfig

type DiscordStateConfig struct {
	Session        *discordgo.Session  // Discord session
	PreferredGuild string              // Which guilds should be checked first for users, good if theres one guild with the majority of users
	BaseState      *dovewing.BaseState // Base state
}

func (DiscordStateConfig) New

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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