CommandRegistry

Stores loaded Commands in a Collection keyed by each Command's name property

Extends

Properties

.groups: string[]

Contains all Command groups

Type:
string[]
Source:

Methods

.registerExternal(command: Command) → void

Register an external command and add it to the <Client>.commands collection, erroring on duplicate aliases

Note: This is intended for Plugins to use to register external commands with the Client instance. Under normal circumstances commands should be added by placing them in the directory passed to the commandsDir YAMDBF Client option

Parameters:
Name Type Description
command
Command

The Command instance to be registered

Source:
Returns:
void

.resolve(input: string)Command | undefined

Resolve the given Command name or alias to a registered Command

Parameters:
Name Type Description
input
string

Command name or alias

Source:
Returns:
Command
|
undefined