Class DominionRenameEvent
java.lang.Object
org.bukkit.event.Event
cn.lunadeer.dominion.events.CallableEvent
cn.lunadeer.dominion.events.ResultEvent
cn.lunadeer.dominion.events.dominion.modify.DominionModifyEvent
cn.lunadeer.dominion.events.dominion.modify.DominionRenameEvent
- All Implemented Interfaces:
org.bukkit.event.Cancellable
Event triggered when a Dominion is renamed in the Dominion system.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bukkit.event.Event
org.bukkit.event.Event.Result -
Constructor Summary
ConstructorsConstructorDescriptionDominionRenameEvent(@NotNull org.bukkit.command.CommandSender operator, @NotNull DominionDTO dominion, @NotNull String newName) Constructs a new DominionRenameEvent. -
Method Summary
Modifier and TypeMethodDescription@NotNull StringGets the new name of the dominion.@NotNull StringGets the old name of the dominion.voidsetNewName(@NotNull String newName) Sets the new name for the dominion.Methods inherited from class cn.lunadeer.dominion.events.dominion.modify.DominionModifyEvent
afterModified, getDominion, getFutureToComplete, setDominionMethods inherited from class cn.lunadeer.dominion.events.ResultEvent
getOperator, isCancelled, setCancelledMethods inherited from class cn.lunadeer.dominion.events.CallableEvent
call, getHandlerList, getHandlersMethods inherited from class org.bukkit.event.Event
callEvent, getEventName, isAsynchronous
-
Constructor Details
-
DominionRenameEvent
public DominionRenameEvent(@NotNull @NotNull org.bukkit.command.CommandSender operator, @NotNull @NotNull DominionDTO dominion, @NotNull @NotNull String newName) Constructs a new DominionRenameEvent.- Parameters:
operator- the command sender who initiated the eventdominion- the dominion to be renamednewName- the new name for the dominion
-
-
Method Details
-
getNewName
Gets the new name of the dominion.- Returns:
- the new name
-
getOldName
Gets the old name of the dominion.- Returns:
- the old name
-
setNewName
Sets the new name for the dominion.- Parameters:
newName- the new name to set
-