-
-
Notifications
You must be signed in to change notification settings - Fork 20
Descriptions
sk89q edited this page Aug 19, 2014
·
1 revision
Descriptions
provide metadata about a command, including:
- A short description (i.e. "Teleports players somewhere").
- A longer help text.
- A usage string (i.e.
<name> [<age>]
). - Accepted parameters for the command.
- A list of permissions that may apply to the command.
This data is not used by the framework, but providing it may be useful if you plan on implementing a help commmand. The list of permissions that is returned is not checked.
Each parameter is a Parameter
type, which information on the parameter:
- The name of the parameter.
- The flag for the parameter, if a flag applied.
- Whether the parameter is a value flag (
-f value
). - Whether the parameter is optional.
- A default value.
Remember, this information is optional.
If you are using the parametric builder, this information will be filled in for you. (However, at the moment, there's no great way for names of parameters to be generated.)
-
SettableDescription
implements theDescription
interface and has setters. -
SettableParameter
implements theParameter
interface and has setters.