Class CommandsExtension
- Namespace
- DSharpPlus.Commands
- Assembly
- DSharpPlus.Commands.dll
An all in one extension for managing commands.
public sealed class CommandsExtension
- Inheritance
-
CommandsExtension
Properties
- Commands
The registered commands that the users can execute.
- DebugGuildId
The guild id to use for debugging. Leave as 0 to disable.
- Processors
All registered command processors.
- RegisterDefaultCommandProcessors
Whether to register default command processors when they're not found in the processor list.
- ServiceProvider
Gets the service provider used within this Discord application.
- UseDefaultCommandErrorHandler
Whether to enable the default command error handler.
Methods
- AddCheck(Type)
Adds a new check to the extension.
- AddCheck<T>()
Adds a new check to the extension.
- AddChecks(Assembly)
Adds all public checks from the provided assembly to the extension.
- AddParameterCheck(Type)
Adds a new check to the extension.
- AddParameterCheck<T>()
Adds a new check to the extension.
- AddParameterChecks(Assembly)
Adds all parameter checks from the provided assembly to the extension.
- GetCommandsForProcessor(ICommandProcessor)
Gets a list of commands filtered for a specific command processor
- Setup(DiscordClient)
Sets up the extension to use the specified DiscordClient.
Events
- CommandErrored
Executed everytime a command has errored.
- CommandExecuted
Executed everytime a command is finished executing.
- ConfiguringCommands
Executed before commands are finalized into a read-only state.