Package net.frozenspace.frostlib.command
Annotation Type Command
-
@Retention(RUNTIME) @Target(METHOD) public @interface CommandThis annotation is used for defining a method to be a PluginCommand, the corp of the method will be executed when someone will perform a command with the selected name
-
-
Required Element Summary
Required Elements Modifier and Type Required Element Description java.lang.StringdescriptionThe description of the command is what is show to players when using /helpjava.lang.StringnameThe name of the command is what the player need to type for executing this command
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description java.lang.String[]aliasesThe command aliases are used for perform a command using aliasesbooleancompletionDefine if the command method have aCompletermethod used for tab completion somewhere in the class by default it's set to falseintmaxArgsDefine the max args allowed for perform this command If player enter more args than this value the command will not be executed by default the value isInteger.MAX_VALUEintminArgsDefine the min args allowed for perform this command If player enter less args than this value the command will not be executed by default the value is 0java.lang.StringpermissionThe permission is the permission needed by the command sender to perform this command by default there is no permission neededjava.lang.StringpermissionMessageThe message send to player who perform this command without the permission by default it's set to "You don't have the permission to perform this command"SendersenderThe command method will be executed only if the sender of the command is the sender needed by default all sender are allowedjava.lang.StringusageUsage is the message sent to the player when the command is badly formatted the default value is /commandname
-
-
-
-
sender
Sender sender
The command method will be executed only if the sender of the command is the sender needed by default all sender are allowed- Returns:
- The sender who should use the command
- Default:
- net.frozenspace.frostlib.command.Sender.ALL
-
-
-
completion
boolean completion
Define if the command method have aCompletermethod used for tab completion somewhere in the class by default it's set to false- Returns:
- Yes if tab completion is enabled false if not
- Default:
- false
-
-
-
permissionMessage
java.lang.String permissionMessage
The message send to player who perform this command without the permission by default it's set to "You don't have the permission to perform this command"- Returns:
- The no permission message to send
- Default:
- "You don\'t have the permission to perform this command"
-
-