Class EconomyTransactionEvent

java.lang.Object
org.bukkit.event.Event
fr.mathildeuh.youneedme.api.event.EconomyTransactionEvent
All Implemented Interfaces:
org.bukkit.event.Cancellable

public class EconomyTransactionEvent extends org.bukkit.event.Event implements org.bukkit.event.Cancellable
Fired before any balance change is persisted - deposit, withdraw, set, or one leg of a /pay transfer (which fires twice: once per account). The account involved may be offline, so this carries a UUID rather than a Player.
  • Constructor Details

  • Method Details

    • getAccount

      public UUID getAccount()
    • getCurrencyId

      public String getCurrencyId()
    • getType

      public EconomyTransactionEvent.Type getType()
    • getAmount

      public double getAmount()
    • getReason

      public String getReason()
      Machine-readable cause, e.g. "pay", "shop-buy", "eco-admin".
    • getRelatedAccount

      @Nullable public @Nullable UUID getRelatedAccount()
      The other party for a transfer (e.g. the /pay recipient), if any.
    • isCancelled

      public boolean isCancelled()
      Specified by:
      isCancelled in interface org.bukkit.event.Cancellable
    • setCancelled

      public void setCancelled(boolean cancel)
      Specified by:
      setCancelled in interface org.bukkit.event.Cancellable
    • 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()