command

package
v0.0.0-...-f8b5f28 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterCommands

func RegisterCommands(registerFunc Register, addTestCommands bool) error

RegisterCommands should be called by the plugin to register all necessary commands

Types

type Register

type Register func(*model.Command) error

Register is a function that allows the runner to register commands with the mattermost server.

type Runner

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

Runner handles commands.

func NewCommandRunner

func NewCommandRunner(ctx *plugin.Context,
	args *model.CommandArgs,
	api *pluginapi.Client,
	logger bot.Logger,
	poster bot.Poster,
	ps app.PruneService,
) *Runner

NewCommandRunner creates a command runner.

func (*Runner) Execute

func (r *Runner) Execute() error

Execute should be called by the plugin when a command invocation is received from the Mattermost server.

Jump to

Keyboard shortcuts

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