commands

package
v1.18.4 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2026 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckCommandAllowedToRun

func CheckCommandAllowedToRun(cmd *cobra.Command, channels configurator.ConfiguratorChannel, channelID types.DiscordChannelID) bool

func CreateConsoler

func CreateConsoler(
	channelInfo *consoler_types.ChannelParams,
	configur *configurator.Configurator,
) *cobra.Command

func GetPoBGoodAlerts added in v1.17.0

func GetStatus

func GetStatus[T any](r ConfStatus[T], channelID types.DiscordChannelID) string

func NewAlertThresholdCommands

func NewAlertThresholdCommands[T configurator.AlertThresholdType](
	cmdGroup *cmdgroup.CmdGroup,
	cfgTags configurator.IConfiguratorAlertThreshold[T],
	channels configurator.ConfiguratorChannel,
	threshold_integer_kind models.ThresholdIntegerKind,
	opts ...AlertThresholdCommandsOption[T],
) *alertThresholdCommands[T]

func NewTagCommands

func NewTagCommands(
	cmd *cmdgroup.CmdGroup,
	cfgTags configurator.IConfiguratorTags,
	channels configurator.ConfiguratorChannel,
	opts ...tagCommandOpt,
) *tagCommands

func PrintList added in v1.6.2

func PrintList[T any](smth []T) string

func WithDisabledAdd added in v1.13.0

func WithDisabledAdd() tagCommandOpt

Types

type AlertBoolCommands

type AlertBoolCommands[T configurator.AlertBoolType] struct {
	*cmdgroup.CmdGroup
	// contains filtered or unexported fields
}

func (*AlertBoolCommands[T]) CreateDisableCmd

func (t *AlertBoolCommands[T]) CreateDisableCmd()

func (*AlertBoolCommands[T]) CreateEnableCmd

func (t *AlertBoolCommands[T]) CreateEnableCmd()

func (*AlertBoolCommands[T]) CreateStatusCmd

func (t *AlertBoolCommands[T]) CreateStatusCmd()

type AlertBoolCommandsOption added in v1.13.0

type AlertBoolCommandsOption[T configurator.AlertBoolType] func(t *AlertBoolCommands[T])

type AlertOption added in v1.13.0

type AlertOption[T configurator.AlertStringType] func(t *AlertSetStringCommand[T])

type AlertSetStringCommand

type AlertSetStringCommand[T configurator.AlertStringType] struct {
	*cmdgroup.CmdGroup
	// contains filtered or unexported fields
}

func NewAlertSetStringCommand

func NewAlertSetStringCommand[T configurator.AlertStringType](
	cmdGroup *cmdgroup.CmdGroup,
	cfgTags configurator.IConfiguratorAlertString[T],
	channels configurator.ConfiguratorChannel,
	allowed_order_keys []types.OrderKey,
	opts ...AlertOption[T],
) *AlertSetStringCommand[T]

func (*AlertSetStringCommand[T]) CreateSetCmd

func (t *AlertSetStringCommand[T]) CreateSetCmd(allowed_order_keys []types.OrderKey)

func (*AlertSetStringCommand[T]) CreateStatusCmd

func (t *AlertSetStringCommand[T]) CreateStatusCmd()

func (*AlertSetStringCommand[T]) CreateUnsetCmd

func (t *AlertSetStringCommand[T]) CreateUnsetCmd()

type AlertThresholdCommandsOption added in v1.13.0

type AlertThresholdCommandsOption[T configurator.AlertThresholdType] func(t *alertThresholdCommands[T])

type ConfStatus

type ConfStatus[T any] interface {
	Status(channelID types.DiscordChannelID) (T, error)
}

type InfoCommands added in v1.9.0

type InfoCommands struct {
	*cmdgroup.CmdGroup
	// contains filtered or unexported fields
}

func NewInfoCommands added in v1.9.0

func NewInfoCommands(
	cmdGroup *cmdgroup.CmdGroup,
	channels configurator.ConfiguratorChannel,
) *InfoCommands

func (*InfoCommands) CreateGetInfoCmd added in v1.9.0

func (t *InfoCommands) CreateGetInfoCmd()

type PoBGoodCommands added in v1.17.0

type PoBGoodCommands[T configurator.AlertPoBGoodType] struct {
	*cmdgroup.CmdGroup
	// contains filtered or unexported fields
}

func NewPoBGoodCommand added in v1.17.0

func (*PoBGoodCommands[T]) CreatePobGoodAdd added in v1.17.0

func (t *PoBGoodCommands[T]) CreatePobGoodAdd()

func (*PoBGoodCommands[T]) CreatePobGoodClear added in v1.17.0

func (t *PoBGoodCommands[T]) CreatePobGoodClear()

func (*PoBGoodCommands[T]) CreatePobGoodRemove added in v1.17.0

func (t *PoBGoodCommands[T]) CreatePobGoodRemove()

func (*PoBGoodCommands[T]) CreatePobGoodThresholdList added in v1.17.0

func (t *PoBGoodCommands[T]) CreatePobGoodThresholdList()

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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