Class CommandTree
java.lang.Object
dev.jorel.commandapi.ExecutableCommand<CommandTree, org.bukkit.command.CommandSender>
dev.jorel.commandapi.AbstractCommandTree<CommandTree, Argument<?>, org.bukkit.command.CommandSender>
dev.jorel.commandapi.CommandTree
- All Implemented Interfaces:
BukkitExecutable<CommandTree>, ChainableBuilder<CommandTree>, PlatformExecutable<CommandTree, org.bukkit.command.CommandSender>
public class CommandTree
extends AbstractCommandTree<CommandTree, Argument<?>, org.bukkit.command.CommandSender>
implements BukkitExecutable<CommandTree>
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected CommandAPIExecutor<org.bukkit.command.CommandSender, AbstractCommandSender<? extends org.bukkit.command.CommandSender>> Fields inherited from class ExecutableCommand
meta -
Constructor Summary
ConstructorsConstructorDescriptionCommandTree(String commandName) Creates a main root node for a command tree with a given command name -
Method Summary
Modifier and TypeMethodDescriptionCommandAPIExecutor<org.bukkit.command.CommandSender, AbstractCommandSender<? extends org.bukkit.command.CommandSender>> instance()voidRegisters the command with a given namespacevoidregister(org.bukkit.plugin.java.JavaPlugin plugin) Registers this command with a givenJavaPlugininstancevoidsetExecutor(CommandAPIExecutor<org.bukkit.command.CommandSender, AbstractCommandSender<? extends org.bukkit.command.CommandSender>> arg0) Methods inherited from class AbstractCommandTree
then, thenNested, thenNestedMethods inherited from class ExecutableCommand
getAliases, getFullDescription, getName, getPermission, getRequirements, getShortDescription, getUsage, override, register, setAliases, setPermission, setRequirements, withAliases, withFullDescription, withHelp, withoutPermission, withoutPermission, withPermission, withPermission, withRequirement, withShortDescription, withUsageMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface BukkitExecutable
executes, executes, executes, executes, executesCommandBlock, executesCommandBlock, executesCommandBlock, executesCommandBlock, executesConsole, executesConsole, executesConsole, executesConsole, executesEntity, executesEntity, executesEntity, executesEntity, executesFeedbackForwarding, executesFeedbackForwarding, executesFeedbackForwarding, executesFeedbackForwarding, executesNative, executesNative, executesNative, executesNative, executesPlayer, executesPlayer, executesPlayer, executesPlayer, executesProxy, executesProxy, executesProxy, executesProxy, executesRemoteConsole, executesRemoteConsole, executesRemoteConsole, executesRemoteConsoleModifier and TypeMethodDescriptiondefault CommandTreeexecutes(CommandExecutionInfo executor, ExecutorType... types) Adds an executor to the current command builderdefault CommandTreeexecutes(CommandExecutor executor, ExecutorType... types) Adds an executor to the current command builderdefault CommandTreeexecutes(ResultingCommandExecutionInfo executor, ExecutorType... types) Adds an executor to the current command builderdefault CommandTreeexecutes(ResultingCommandExecutor executor, ExecutorType... types) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesConsole(ConsoleCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesEntity(EntityCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesEntity(EntityResultingCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesNative(NativeCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesNative(NativeResultingCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesPlayer(PlayerCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesPlayer(PlayerResultingCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesProxy(ProxyCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeexecutesProxy(ProxyResultingCommandExecutor executor) Adds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderdefault CommandTreeAdds an executor to the current command builderMethods inherited from interface PlatformExecutable
getExecutor
-
Field Details
-
executor
protected CommandAPIExecutor<org.bukkit.command.CommandSender, AbstractCommandSender<? extends org.bukkit.command.CommandSender>> executor
-
-
Constructor Details
-
CommandTree
Creates a main root node for a command tree with a given command name- Parameters:
commandName- The name of the command to create
-
-
Method Details
-
instance
- Specified by:
instancein interfaceChainableBuilder<CommandTree>
-
register
Registers the command with a given namespace- Overrides:
registerin classAbstractCommandTree<CommandTree, Argument<?>, org.bukkit.command.CommandSender>- Parameters:
namespace- The namespace of this command. This cannot be null or empty
-
register
public void register(org.bukkit.plugin.java.JavaPlugin plugin) Registers this command with a givenJavaPlugininstance- Parameters:
plugin- The plugin instance used to determine this command's namespace
-
getExecutor
public CommandAPIExecutor<org.bukkit.command.CommandSender, AbstractCommandSender<? extends org.bukkit.command.CommandSender>> getExecutor() -
setExecutor
public void setExecutor(CommandAPIExecutor<org.bukkit.command.CommandSender, AbstractCommandSender<? extends org.bukkit.command.CommandSender>> arg0) -
clearExecutors
-