Record Class UserAttributesResponse.BanStatus.BannedScope

java.lang.Object
java.lang.Record
com.mojang.authlib.yggdrasil.response.UserAttributesResponse.BanStatus.BannedScope
Enclosing class:
UserAttributesResponse.BanStatus

public static record UserAttributesResponse.BanStatus.BannedScope(UUID banId, @Nullable Instant expires, String reason, @Nullable String reasonMessage) extends Record
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final UUID
    The field for the banId record component.
    private final Instant
    The field for the expires record component.
    private final String
    The field for the reason record component.
    private final String
    The field for the reasonMessage record component.
  • Constructor Summary

    Constructors
    Constructor
    Description
    BannedScope(UUID banId, Instant expires, String reason, String reasonMessage)
    Creates an instance of a BannedScope record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the value of the banId record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    Returns the value of the expires record component.
    final int
    Returns a hash code value for this object.
    Returns the value of the reason record component.
    Returns the value of the reasonMessage record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Field Details

    • banId

      @SerializedName("banId") private final UUID banId
      The field for the banId record component.
    • expires

      @SerializedName("expires") @Nullable private final Instant expires
      The field for the expires record component.
    • reason

      @SerializedName("reason") private final String reason
      The field for the reason record component.
    • reasonMessage

      @SerializedName("reasonMessage") @Nullable private final String reasonMessage
      The field for the reasonMessage record component.
  • Constructor Details

    • BannedScope

      public BannedScope(UUID banId, @Nullable Instant expires, String reason, @Nullable String reasonMessage)
      Creates an instance of a BannedScope record class.
      Parameters:
      banId - the value for the banId record component
      expires - the value for the expires record component
      reason - the value for the reason record component
      reasonMessage - the value for the reasonMessage record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • banId

      @SerializedName("banId") public UUID banId()
      Returns the value of the banId record component.
      Returns:
      the value of the banId record component
    • expires

      @SerializedName("expires") @Nullable public Instant expires()
      Returns the value of the expires record component.
      Returns:
      the value of the expires record component
    • reason

      @SerializedName("reason") public String reason()
      Returns the value of the reason record component.
      Returns:
      the value of the reason record component
    • reasonMessage

      @SerializedName("reasonMessage") @Nullable public String reasonMessage()
      Returns the value of the reasonMessage record component.
      Returns:
      the value of the reasonMessage record component