Class DeleteTownEvent

java.lang.Object
org.bukkit.event.Event
com.palmergames.bukkit.towny.event.DeleteTownEvent

public class DeleteTownEvent extends org.bukkit.event.Event
  • Field Details

    • name

      protected final String name
    • uuid

      protected final UUID uuid
    • registered

      protected final long registered
  • Constructor Details

    • DeleteTownEvent

      public DeleteTownEvent(@NotNull @NotNull Town town, @Nullable @Nullable Resident mayor, @NotNull @NotNull DeleteTownEvent.Cause cause, @Nullable @Nullable org.bukkit.command.CommandSender sender)
  • Method Details

    • getTownName

      public String getTownName()
      Returns:
      the deleted town name.
    • getTownUUID

      public UUID getTownUUID()
      Returns:
      the deleted town uuid.
    • getTownCreated

      public long getTownCreated()
      Returns:
      the deleted town's time of creation (in epoch ms).
    • getMayorUUID

      @Nullable public @Nullable UUID getMayorUUID()
      Returns:
      the deleted town's mayor's UUID, or null.
    • getMayor

      @Nullable public @Nullable Resident getMayor()
      Returns:
      The deleted town's mayor, or null.
    • getCause

      @NotNull public @NotNull DeleteTownEvent.Cause getCause()
    • getSender

      @Nullable public @Nullable org.bukkit.command.CommandSender getSender()
      Returns:
      The command sender who caused the deletion
    • getSenderResident

      @Nullable public @Nullable Resident getSenderResident()
      Returns:
      The getSender() as a resident.
    • getHandlers

      @NotNull public @NotNull org.bukkit.event.HandlerList getHandlers()
      Specified by:
      getHandlers in class org.bukkit.event.Event
    • getHandlerList

      public static org.bukkit.event.HandlerList getHandlerList()