Interface CommandTreeNodeType<T extends CommandTreeNode<T>>
-
- All Superinterfaces:
DefaultedRegistryValue
,Keyed
,ResourceKeyed
@CatalogedBy(CommandTreeNodeTypes.class) public interface CommandTreeNodeType<T extends CommandTreeNode<T>> extends DefaultedRegistryValue, ResourceKeyed
Represents the client-side behavior of aCommandTreeNode
, for use withcommand registrars
that require such nodes to specify client side behaviour (for example,raw commands
).These types affect the following behaviours of client-side command handling:
- The allowed form of an argument - i.e. how the client decides an argument will be accepted or not.
- The available tab-completions for a given argument (which may either be wholly client-side, or require a request to the server).
Some of these types may have an alternative
completion provider
that may be used in conjunction with this node type that provides alternative completions.Note that these types do not contain any parsing logic themselves, they are purely used to inform the client of the behavior it should exhibit when displaying and completing command strings.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description T
createNode()
Creates aCommandTreeNode
that represents thisCommandTreeNodeType
-
Methods inherited from interface org.spongepowered.api.registry.DefaultedRegistryValue
asDefaultedReference, findKey, key
-
Methods inherited from interface org.spongepowered.api.ResourceKeyed
key
-
-
-
-
Method Detail
-
createNode
T createNode()
Creates aCommandTreeNode
that represents thisCommandTreeNodeType
- Returns:
- The new
CommandTreeNode
-
-