public class BukkitPartiesPartyPreRenameEvent extends BukkitPartiesEvent implements IPartyPreRenameEvent, org.bukkit.event.Cancellable
| Constructor and Description |
|---|
BukkitPartiesPartyPreRenameEvent(Party party,
String oldName,
String newName,
PartyPlayer player,
boolean isAdmin) |
| Modifier and Type | Method and Description |
|---|---|
@Nullable String |
getNewPartyName()
Get the new party name
|
@Nullable String |
getOldPartyName()
Get the old party name
|
@NotNull Party |
getParty()
Get the party that is getting renamed
|
@Nullable PartyPlayer |
getPartyPlayer()
Get the player who performed the command
|
boolean |
isAdmin()
Is it an admin renaming?
|
boolean |
isCancelled()
Is the event cancelled?
|
void |
setCancelled(boolean cancel)
Set the event as cancelled
|
void |
setNewPartyName(String name)
Set the new name of the party
|
getApi, getHandlerList, getHandlers, setApiclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetApi, setApipublic BukkitPartiesPartyPreRenameEvent(Party party, String oldName, String newName, PartyPlayer player, boolean isAdmin)
@NotNull public @NotNull Party getParty()
IPartyPreRenameEventgetParty in interface IPartyPreRenameEventParty@Nullable public @Nullable String getOldPartyName()
IPartyPreRenameEventgetOldPartyName in interface IPartyPreRenameEvent@Nullable public @Nullable String getNewPartyName()
IPartyPreRenameEventgetNewPartyName in interface IPartyPreRenameEventpublic void setNewPartyName(String name)
IPartyPreRenameEventsetNewPartyName in interface IPartyPreRenameEventname - the party name to set@Nullable public @Nullable PartyPlayer getPartyPlayer()
IPartyPreRenameEventgetPartyPlayer in interface IPartyPreRenameEventPartyPlayer or null if not executed by a playerpublic boolean isAdmin()
IPartyPreRenameEventisAdmin in interface IPartyPreRenameEventtrue if the rename has been performed by an adminpublic boolean isCancelled()
CancellableisCancelled in interface org.bukkit.event.Cancellabletrue if the event is cancelledpublic void setCancelled(boolean cancel)
CancellablesetCancelled in interface org.bukkit.event.Cancellablecancel - true to cancelCopyright © 2023. All rights reserved.