Class BossbarSendEvent
java.lang.Object
me.remigio07.chatplugin.api.server.event.bossbar.BossbarSendEvent
- All Implemented Interfaces:
CancellableEvent
,ChatPluginEvent
,ChatPluginPlayerEvent
,ChatPluginServerPlayerEvent
public class BossbarSendEvent
extends Object
implements CancellableEvent, ChatPluginServerPlayerEvent
Represents an event called when a
Bossbar
is sent to a player.-
Constructor Summary
ConstructorDescriptionBossbarSendEvent
(Bossbar bossbar, ChatPluginServerPlayer player) Constructs a new bossbar send event. -
Method Summary
Modifier and TypeMethodDescriptionGets the bossbar sent to the player.Gets the player involved with this event.boolean
Checks if this event has been cancelled and will not be executed.void
setCancelled
(boolean cancelled) Sets the cancellation state of this event.Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface me.remigio07.chatplugin.api.common.event.ChatPluginEvent
call
-
Constructor Details
-
BossbarSendEvent
Constructs a new bossbar send event.- Parameters:
bossbar
- Bossbar involvedplayer
- Player involved
-
-
Method Details
-
isCancelled
public boolean isCancelled()Description copied from interface:CancellableEvent
Checks if this event has been cancelled and will not be executed.- Specified by:
isCancelled
in interfaceCancellableEvent
- Returns:
- Whether this event is cancelled
-
setCancelled
public void setCancelled(boolean cancelled) Description copied from interface:CancellableEvent
Sets the cancellation state of this event.It will be passed through other registered listeners even if it is cancelled, but it will not be executed.
- Specified by:
setCancelled
in interfaceCancellableEvent
- Parameters:
cancelled
- Whether this event should be cancelled
-
getPlayer
Description copied from interface:ChatPluginServerPlayerEvent
Gets the player involved with this event.- Specified by:
getPlayer
in interfaceChatPluginPlayerEvent
- Specified by:
getPlayer
in interfaceChatPluginServerPlayerEvent
- Returns:
- Player involved
-
getBossbar
Gets the bossbar sent to the player.- Returns:
- Bossbar sent
-