Interface ICommandParameterDescriptor
- Namespace
- Uncreated.Warfare.Interaction.Commands.Syntax
- Assembly
- Uncreated.Warfare.dll
Describes a command or parameter for a command (including sub-commands).
public interface ICommandParameterDescriptor
Properties
Aliases
Values that can be entered instead of Name.
IReadOnlyList<string> Aliases { get; }
Property Value
Chain
Number of sub-parameters to chain into one 'parameter' including this one. Requires that all child parameters up to that amount have only one parameter.
int Chain { get; }
Property Value
Remarks
Example: /tp [x y z|location|player] where x.ChainDisplayAmount = 3.
Description
Translatable description of the command or sub-command.
TranslationList? Description { get; }
Property Value
Flags
List of valid flags for this command or parameter.
IReadOnlyList<ICommandFlagDescriptor> Flags { get; }
Property Value
Name
Name of the parameter in proper-case format.
string Name { get; }
Property Value
Optional
If the parameter is optional. All other parameters on this level must also be marked optional.
bool Optional { get; }
Property Value
Parameters
List of sub-parameters.
IReadOnlyList<ICommandParameterDescriptor> Parameters { get; }
Property Value
Parent
The parent of this parameter descriptor, if any.
ICommandParameterDescriptor? Parent { get; }
Property Value
Permission
The permission needed to use this parameter.
PermissionLeaf Permission { get; }
Property Value
Remainder
If the parameter spans the rest of the command arguments, including spaces.
bool Remainder { get; }
Property Value
Types
List of valid types that can be used for this parameter.
IReadOnlyList<Type> Types { get; }
Property Value
Remarks
Verbatim parameter types will have the type of VerbatimParameterType.