I - the type of the command invocation objectpublic interface InvocableCommand<I extends CommandInvocation<?>> extends Command
| Modifier and Type | Method and Description |
|---|---|
void |
execute(I invocation)
Executes the command for the specified invocation.
|
default boolean |
hasPermission(I invocation)
Tests to check if the source has permission to perform the specified invocation.
|
default List<String> |
suggest(I invocation)
Provides tab complete suggestions for the specified invocation.
|
default CompletableFuture<List<String>> |
suggestAsync(I invocation)
Provides tab complete suggestions for the specified invocation.
|
execute, hasPermission, suggest, suggestAsyncvoid execute(I invocation)
invocation - the invocation contextdefault List<String> suggest(I invocation)
invocation - the invocation contextdefault CompletableFuture<List<String>> suggestAsync(I invocation)
invocation - the invocation contextdefault boolean hasPermission(I invocation)
If the method returns false, the handling is forwarded onto
the players current server.
invocation - the invocation contexttrue if the source has permission