Class TownPreTransactionEvent

java.lang.Object
org.bukkit.event.Event
com.palmergames.bukkit.towny.event.CancellableTownyEvent
com.palmergames.bukkit.towny.event.economy.TownPreTransactionEvent
All Implemented Interfaces:
org.bukkit.event.Cancellable

public class TownPreTransactionEvent extends CancellableTownyEvent
An Cancellable event thrown when a Town BankAccount is about to either receive or pay money.
  • Constructor Details

    • TownPreTransactionEvent

      public TownPreTransactionEvent(Town town, Transaction transaction)
      An Cancellable event thrown when a Town BankAccount is about to either receive or pay money.
      Parameters:
      town - Town whose account which is paying or receiving money.
      transaction - Transaction which will be occuring.
  • Method Details

    • getTown

      public Town getTown()
      Returns:
      Town
    • getTransaction

      public Transaction getTransaction()
      Returns:
      Transaction which will be occuring.
    • getNewBalance

      public int getNewBalance()
      Returns:
      the future balance of the Town BankAccount if this event is not cancelled.
    • getHandlerList

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

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