CommandAPI 9.3.0
An API for the command UI introduced in Minecraft 1.13
dev.jorel.commandapi.executors.NormalExecutor< CommandSender, WrapperType > Interface Template Reference

The interface for normal command executors. More...

+ Inheritance diagram for dev.jorel.commandapi.executors.NormalExecutor< CommandSender, WrapperType >:

Public Member Functions

default int executeWith (ExecutionInfo< CommandSender, WrapperType > info) throws WrapperCommandSyntaxException
 Executes the command executor with the provided command sender and the provided arguments. More...
 
void run (ExecutionInfo< CommandSender, WrapperType > info) throws WrapperCommandSyntaxException
 Executes the command. More...
 
default ExecutorType getType ()
 Returns the type of the sender of the current executor. More...
 

Detailed Description

The interface for normal command executors.

Parameters
<CommandSender>The CommandSender for this executor
<WrapperType>The AbstractCommandSender that wraps the CommandSender

Member Function Documentation

◆ executeWith()

default int dev.jorel.commandapi.executors.NormalExecutor< CommandSender, WrapperType >.executeWith ( ExecutionInfo< CommandSender, WrapperType >  info) throws WrapperCommandSyntaxException

Executes the command executor with the provided command sender and the provided arguments.

Parameters
infoThe ExecutionInfo for this command
Returns
1 if the command succeeds, 0 if the command fails
Exceptions
WrapperCommandSyntaxExceptionif an error occurs during the execution of this command

Implements dev.jorel.commandapi.executors.TypedExecutor< CommandSender, WrapperType >.

◆ getType()

default ExecutorType dev.jorel.commandapi.executors.TypedExecutor< CommandSender, WrapperType >.getType ( )
inherited

Returns the type of the sender of the current executor.

Returns
the type of the sender of the current executor

◆ run()

void dev.jorel.commandapi.executors.NormalExecutor< CommandSender, WrapperType >.run ( ExecutionInfo< CommandSender, WrapperType >  info) throws WrapperCommandSyntaxException

Executes the command.

Parameters
infoThe ExecutionInfo for this command
Exceptions
WrapperCommandSyntaxExceptionif an error occurs during the execution of this command