Interface ClaimEvent

All Superinterfaces:
Event
All Known Subinterfaces:
AttackPlayerEvent, BorderClaimEvent, ChangeClaimEvent, ChangeClaimEvent.DisplayName, ChangeClaimEvent.Identifier, ChangeClaimEvent.Resize, ChangeClaimEvent.Type, ClanTrustClaimEvent, ClanTrustClaimEvent.Add, ClanTrustClaimEvent.Remove, CreateClaimEvent, CreateClaimEvent.Post, CreateClaimEvent.Pre, GroupTrustClaimEvent, GroupTrustClaimEvent.Add, GroupTrustClaimEvent.Remove, LoadClaimEvent, LoadClaimEvent.Post, LoadClaimEvent.Pre, PermissionIdentifyEvent, ProcessInteractBlockEvent, ProcessTrustUserEvent, RemoveClaimEvent, RemoveClaimEvent.Abandon, RemoveClaimEvent.Delete, RemoveClaimEvent.Expire, RentClaimEvent, SaveClaimEvent, SaveClaimEvent.Post, SaveClaimEvent.Pre, TaxClaimEvent, TransferClaimEvent, TrustClaimEvent, TrustClaimEvent.Add, TrustClaimEvent.Remove, UserTrustClaimEvent, UserTrustClaimEvent.Add, UserTrustClaimEvent.Remove

public interface ClaimEvent extends Event
Base event when one or more Claims are affected.
  • Method Summary

    Modifier and Type
    Method
    Description
    default Claim
    Gets the first claim.
    Gets the immutable list of claims.
    Optional<net.kyori.adventure.text.Component>
    Gets the claim message.
    The source object that caused this event.
    @Nullable User
    The source User that caused this event.
    void
    setMessage(net.kyori.adventure.text.Component message)
    Sets the claim message to be presented to Subject if applicable.

    Methods inherited from interface com.griefdefender.api.event.Event

    getCause
  • Method Details

    • getSource

      Object getSource()
      The source object that caused this event.
      Note: If no source available, pass mod/plugin instance.
      Returns:
      The source
    • getSourceUser

      @Nullable User getSourceUser()
      The source User that caused this event.
      Returns:
      The source user, if available
    • getClaims

      List<Claim> getClaims()
      Gets the immutable list of claims.
      Returns:
      The immutable list of claims
    • getClaim

      default Claim getClaim()
      Gets the first claim. Note: This is a helper method for events that will usually always contain one claim instead of calling getClaims().
      Returns:
      The first claim
    • setMessage

      void setMessage(net.kyori.adventure.text.Component message)
      Sets the claim message to be presented to Subject if applicable.
      Parameters:
      message - The message
    • getMessage

      Optional<net.kyori.adventure.text.Component> getMessage()
      Gets the claim message. Note: This is only available if event was cancelled.
      Returns:
      The claim message, if available