CommandManager
class
CommandManager
sourceexport class CommandManager export class CommandManager get source
.applicationCommands()
applicationCommands() applicationCommands()add<T extends CommandType>(data: AnyCommandResolvable<T>): this add<T extends CommandType>(data: AnyCommandResolvable<T>): this| Param | Type | Required |
|---|---|---|
| | Yes |
Returns:
this thisremove(resolvable: AnyCommandResolvable|string): this remove(resolvable: AnyCommandResolvable|string): this| Param | Type | Required |
|---|---|---|
| | Yes |
Returns:
this thisget<T extends CommandType>(type: T, name: string): AnyCommand<T>|undefined get<T extends CommandType>(type: T, name: string): AnyCommand<T>|undefined| Param | Type | Required |
|---|---|---|
| | Yes |
| | Yes |
Returns:
AnyCommand<T>|undefined AnyCommand<T>|undefinedregisterApplicationCommands(options?: CommandManager.RegisterApplicationCommandsOptions): Promise<CommandManager.RegisteredCommandsData> registerApplicationCommands(options?: CommandManager.RegisterApplicationCommandsOptions): Promise<CommandManager.RegisteredCommandsData>| Param | Type | Required |
|---|---|---|
| | No |
Returns:
Promise<CommandManager.RegisteredCommandsData> Promise<CommandManager.RegisteredCommandsData>private source
.emitOrThrow(...)
emitOrThrow(error: unknown): boolean emitOrThrow(error: unknown): boolean| Param | Type | Required |
|---|---|---|
| | Yes |
Returns:
boolean booleanConstructable<AnyCommand> Constructable<AnyCommand>