Package top.focess.qq.api.event.command
Class CommandPrepostEvent
- java.lang.Object
-
- top.focess.qq.api.event.Event
-
- top.focess.qq.api.event.command.CommandPrepostEvent
-
- All Implemented Interfaces:
Serializable,Cancellable
public class CommandPrepostEvent extends Event implements Cancellable
Called before command executing- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CommandPrepostEvent(CommandSender sender, Command command, String[] args, IOHandler ioHandler)Constructs a CommandPrepostEvent
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String[]getArgs()CommandgetCommand()IOHandlergetIoHandler()CommandSendergetSender()booleanisCancelled()Indicate this event is cancelledvoidsetCancelled(boolean cancelled)Set whether this event is cancelled or not-
Methods inherited from class top.focess.qq.api.event.Event
isPrevent, setPrevent
-
-
-
-
Constructor Detail
-
CommandPrepostEvent
public CommandPrepostEvent(CommandSender sender, Command command, String[] args, IOHandler ioHandler)
Constructs a CommandPrepostEvent- Parameters:
sender- the executorcommand- the Commandargs- the data of this executorioHandler- the input and output handler
-
-
Method Detail
-
isCancelled
public boolean isCancelled()
Description copied from interface:CancellableIndicate this event is cancelled- Specified by:
isCancelledin interfaceCancellable- Returns:
- true if this event is cancelled, false otherwise
-
setCancelled
public void setCancelled(boolean cancelled)
Description copied from interface:CancellableSet whether this event is cancelled or not- Specified by:
setCancelledin interfaceCancellable- Parameters:
cancelled- whether this event is cancelled or not
-
getArgs
public String[] getArgs()
-
getIoHandler
public IOHandler getIoHandler()
-
getSender
public CommandSender getSender()
-
getCommand
public Command getCommand()
-
-