Class ChatPunishmentEvent
java.lang.Object
org.bukkit.event.Event
studio.thevipershow.safechat.api.events.ChatCheckEvent
studio.thevipershow.safechat.api.events.ChatPunishmentEvent
- All Implemented Interfaces:
org.bukkit.event.Cancellable
public class ChatPunishmentEvent extends ChatCheckEvent implements org.bukkit.event.Cancellable
An event called when a check punishment is going to be triggered.
Cancelling this event will cause the punishment to not be executed
anymore.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bukkit.event.Event
org.bukkit.event.Event.Result -
Field Summary
Fields Modifier and Type Field Description static org.bukkit.event.HandlerListhandlerList -
Constructor Summary
Constructors Constructor Description ChatPunishmentEvent(@NotNull Check check)This constructor is used to explicitly declare an event as synchronous or asynchronous. -
Method Summary
Modifier and Type Method Description static @NotNull org.bukkit.event.HandlerListgetHandlerList()@NotNull org.bukkit.event.HandlerListgetHandlers()booleanisCancelled()Gets the cancellation state of this event.voidsetCancelled(boolean cancel)Sets the cancellation state of this event.Methods inherited from class studio.thevipershow.safechat.api.events.ChatCheckEvent
getCheckMethods inherited from class org.bukkit.event.Event
getEventName, isAsynchronousMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
handlerList
public static final org.bukkit.event.HandlerList handlerList
-
-
Constructor Details
-
ChatPunishmentEvent
This constructor is used to explicitly declare an event as synchronous or asynchronous.- Parameters:
check-
-
-
Method Details
-
getHandlerList
@NotNull public static @NotNull org.bukkit.event.HandlerList getHandlerList() -
getHandlers
@NotNull public @NotNull org.bukkit.event.HandlerList getHandlers()- Specified by:
getHandlersin classorg.bukkit.event.Event
-
isCancelled
public boolean isCancelled()Gets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins- Specified by:
isCancelledin interfaceorg.bukkit.event.Cancellable- Returns:
- true if this event is cancelled
-
setCancelled
public void setCancelled(boolean cancel)Sets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins.- Specified by:
setCancelledin interfaceorg.bukkit.event.Cancellable- Parameters:
cancel- true if you wish to cancel this event
-