Class ImmutablePermission

java.lang.Object
org.xrpl.xrpl4j.model.transactions.ImmutablePermission
All Implemented Interfaces:
Permission

@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutablePermission extends Object implements Permission
Immutable implementation of Permission.

Use the builder to create immutable instances: ImmutablePermission.builder().

  • Method Details

    • permissionValue

      public String permissionValue()
      The transaction type that is being delegated, represented as a string.
      Specified by:
      permissionValue in interface Permission
      Returns:
      A String representing the transaction type.
    • withPermissionValue

      public final ImmutablePermission withPermissionValue(String value)
      Copy the current immutable object by setting a value for the permissionValue attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for permissionValue
      Returns:
      A modified copy of the this object
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of ImmutablePermission that have equal attribute values.
      Overrides:
      equals in class Object
      Returns:
      true if this is equal to another instance
    • hashCode

      public int hashCode()
      Computes a hash code from attributes: permissionValue.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

      public String toString()
      Prints the immutable value Permission with attribute values.
      Overrides:
      toString in class Object
      Returns:
      A string representation of the value
    • copyOf

      public static ImmutablePermission copyOf(Permission instance)
      Creates an immutable copy of a Permission value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.
      Parameters:
      instance - The instance to copy
      Returns:
      A copied immutable Permission instance
    • builder

      public static ImmutablePermission.Builder builder()
      Creates a builder for ImmutablePermission.
       ImmutablePermission.builder()
          .permissionValue(String) // required permissionValue
          .build();
       
      Returns:
      A new ImmutablePermission builder