Class ImmutableSignerEntry

java.lang.Object
org.xrpl.xrpl4j.model.ledger.ImmutableSignerEntry
All Implemented Interfaces:
SignerEntry

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

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

  • Method Details

    • account

      public Address account()
      An XRP Ledger classic Address whose signature contributes to the multi-signature. It does not need to be a funded address in the ledger.
      Specified by:
      account in interface SignerEntry
      Returns:
      The Address of the signer.
    • signerWeight

      public com.google.common.primitives.UnsignedInteger signerWeight()
      The weight of a signature from this signer. A multi-signature is only valid if the sum weight of the signatures provided meets or exceeds the SignerListObject.signerQuorum() value.
      Specified by:
      signerWeight in interface SignerEntry
      Returns:
      An UnsignedInteger representing the signer weight.
    • withAccount

      public final ImmutableSignerEntry withAccount(Address value)
      Copy the current immutable object by setting a value for the account attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for account
      Returns:
      A modified copy of the this object
    • withSignerWeight

      public final ImmutableSignerEntry withSignerWeight(com.google.common.primitives.UnsignedInteger value)
      Copy the current immutable object by setting a value for the signerWeight attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for signerWeight
      Returns:
      A modified copy of the this object
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of ImmutableSignerEntry 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: account, signerWeight.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

      public static ImmutableSignerEntry copyOf(SignerEntry instance)
      Creates an immutable copy of a SignerEntry 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 SignerEntry instance
    • builder

      public static ImmutableSignerEntry.Builder builder()
      Creates a builder for ImmutableSignerEntry.
       ImmutableSignerEntry.builder()
          .account(org.xrpl.xrpl4j.model.transactions.Address) // required account
          .signerWeight(com.google.common.primitives.UnsignedInteger) // required signerWeight
          .build();
       
      Returns:
      A new ImmutableSignerEntry builder