Class ImmutableAccountRootObject.Builder

java.lang.Object
org.xrpl.xrpl4j.model.ledger.ImmutableAccountRootObject.Builder
Enclosing class:
ImmutableAccountRootObject

@NotThreadSafe public static final class ImmutableAccountRootObject.Builder extends Object
Builds instances of type ImmutableAccountRootObject. Initialize attributes and then invoke the build() method to create an immutable instance.

Builder is not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.

  • Method Details

    • from

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder from(AccountRootObject instance)
      Fill a builder with attribute values from the provided AccountRootObject instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • account

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder account(Address account)
      Initializes the value for the account attribute.
      Parameters:
      account - The value for account
      Returns:
      this builder for use in a chained invocation
    • balance

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder balance(XrpCurrencyAmount balance)
      Initializes the value for the balance attribute.
      Parameters:
      balance - The value for balance
      Returns:
      this builder for use in a chained invocation
    • flags

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder flags(AccountRootFlags flags)
      Initializes the value for the flags attribute.
      Parameters:
      flags - The value for flags
      Returns:
      this builder for use in a chained invocation
    • ownerCount

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder ownerCount(com.google.common.primitives.UnsignedInteger ownerCount)
      Initializes the value for the ownerCount attribute.
      Parameters:
      ownerCount - The value for ownerCount
      Returns:
      this builder for use in a chained invocation
    • previousTransactionId

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder previousTransactionId(Hash256 previousTransactionId)
      Initializes the value for the previousTransactionId attribute.
      Parameters:
      previousTransactionId - The value for previousTransactionId
      Returns:
      this builder for use in a chained invocation
    • previousTransactionLedgerSequence

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder previousTransactionLedgerSequence(com.google.common.primitives.UnsignedInteger previousTransactionLedgerSequence)
      Initializes the value for the previousTransactionLedgerSequence attribute.
      Parameters:
      previousTransactionLedgerSequence - The value for previousTransactionLedgerSequence
      Returns:
      this builder for use in a chained invocation
    • sequence

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder sequence(com.google.common.primitives.UnsignedInteger sequence)
      Initializes the value for the sequence attribute.
      Parameters:
      sequence - The value for sequence
      Returns:
      this builder for use in a chained invocation
    • accountTransactionId

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder accountTransactionId(Hash256 accountTransactionId)
      Initializes the optional value accountTransactionId to accountTransactionId.
      Parameters:
      accountTransactionId - The value for accountTransactionId
      Returns:
      this builder for chained invocation
    • accountTransactionId

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder accountTransactionId(Optional<? extends Hash256> accountTransactionId)
      Initializes the optional value accountTransactionId to accountTransactionId.
      Parameters:
      accountTransactionId - The value for accountTransactionId
      Returns:
      this builder for use in a chained invocation
    • domain

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder domain(String domain)
      Initializes the optional value domain to domain.
      Parameters:
      domain - The value for domain
      Returns:
      this builder for chained invocation
    • domain

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder domain(Optional<String> domain)
      Initializes the optional value domain to domain.
      Parameters:
      domain - The value for domain
      Returns:
      this builder for use in a chained invocation
    • emailHash

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder emailHash(String emailHash)
      Initializes the optional value emailHash to emailHash.
      Parameters:
      emailHash - The value for emailHash
      Returns:
      this builder for chained invocation
    • emailHash

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder emailHash(Optional<String> emailHash)
      Initializes the optional value emailHash to emailHash.
      Parameters:
      emailHash - The value for emailHash
      Returns:
      this builder for use in a chained invocation
    • messageKey

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder messageKey(String messageKey)
      Initializes the optional value messageKey to messageKey.
      Parameters:
      messageKey - The value for messageKey
      Returns:
      this builder for chained invocation
    • messageKey

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder messageKey(Optional<String> messageKey)
      Initializes the optional value messageKey to messageKey.
      Parameters:
      messageKey - The value for messageKey
      Returns:
      this builder for use in a chained invocation
    • regularKey

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder regularKey(Address regularKey)
      Initializes the optional value regularKey to regularKey.
      Parameters:
      regularKey - The value for regularKey
      Returns:
      this builder for chained invocation
    • regularKey

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder regularKey(Optional<? extends Address> regularKey)
      Initializes the optional value regularKey to regularKey.
      Parameters:
      regularKey - The value for regularKey
      Returns:
      this builder for use in a chained invocation
    • tickSize

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder tickSize(com.google.common.primitives.UnsignedInteger tickSize)
      Initializes the optional value tickSize to tickSize.
      Parameters:
      tickSize - The value for tickSize
      Returns:
      this builder for chained invocation
    • tickSize

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder tickSize(Optional<? extends com.google.common.primitives.UnsignedInteger> tickSize)
      Initializes the optional value tickSize to tickSize.
      Parameters:
      tickSize - The value for tickSize
      Returns:
      this builder for use in a chained invocation
    • transferRate

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder transferRate(com.google.common.primitives.UnsignedInteger transferRate)
      Initializes the optional value transferRate to transferRate.
      Parameters:
      transferRate - The value for transferRate
      Returns:
      this builder for chained invocation
    • transferRate

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder transferRate(Optional<? extends com.google.common.primitives.UnsignedInteger> transferRate)
      Initializes the optional value transferRate to transferRate.
      Parameters:
      transferRate - The value for transferRate
      Returns:
      this builder for use in a chained invocation
    • addSignerLists

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder addSignerLists(SignerListObject element)
      Adds one element to signerLists list.
      Parameters:
      element - A signerLists element
      Returns:
      this builder for use in a chained invocation
    • addSignerLists

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder addSignerLists(SignerListObject... elements)
      Adds elements to signerLists list.
      Parameters:
      elements - An array of signerLists elements
      Returns:
      this builder for use in a chained invocation
    • signerLists

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder signerLists(Iterable<? extends SignerListObject> elements)
      Sets or replaces all elements for signerLists list.
      Parameters:
      elements - An iterable of signerLists elements
      Returns:
      this builder for use in a chained invocation
    • addAllSignerLists

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder addAllSignerLists(Iterable<? extends SignerListObject> elements)
      Adds elements to signerLists list.
      Parameters:
      elements - An iterable of signerLists elements
      Returns:
      this builder for use in a chained invocation
    • ticketCount

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder ticketCount(com.google.common.primitives.UnsignedInteger ticketCount)
      Initializes the optional value ticketCount to ticketCount.
      Parameters:
      ticketCount - The value for ticketCount
      Returns:
      this builder for chained invocation
    • ticketCount

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder ticketCount(Optional<? extends com.google.common.primitives.UnsignedInteger> ticketCount)
      Initializes the optional value ticketCount to ticketCount.
      Parameters:
      ticketCount - The value for ticketCount
      Returns:
      this builder for use in a chained invocation
    • burnedNfTokens

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder burnedNfTokens(com.google.common.primitives.UnsignedInteger burnedNfTokens)
      Initializes the optional value burnedNfTokens to burnedNfTokens.
      Parameters:
      burnedNfTokens - The value for burnedNfTokens
      Returns:
      this builder for chained invocation
    • burnedNfTokens

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder burnedNfTokens(Optional<? extends com.google.common.primitives.UnsignedInteger> burnedNfTokens)
      Initializes the optional value burnedNfTokens to burnedNfTokens.
      Parameters:
      burnedNfTokens - The value for burnedNfTokens
      Returns:
      this builder for use in a chained invocation
    • mintedNfTokens

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder mintedNfTokens(com.google.common.primitives.UnsignedInteger mintedNfTokens)
      Initializes the optional value mintedNfTokens to mintedNfTokens.
      Parameters:
      mintedNfTokens - The value for mintedNfTokens
      Returns:
      this builder for chained invocation
    • mintedNfTokens

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder mintedNfTokens(Optional<? extends com.google.common.primitives.UnsignedInteger> mintedNfTokens)
      Initializes the optional value mintedNfTokens to mintedNfTokens.
      Parameters:
      mintedNfTokens - The value for mintedNfTokens
      Returns:
      this builder for use in a chained invocation
    • nfTokenMinter

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder nfTokenMinter(Address nfTokenMinter)
      Initializes the optional value nfTokenMinter to nfTokenMinter.
      Parameters:
      nfTokenMinter - The value for nfTokenMinter
      Returns:
      this builder for chained invocation
    • nfTokenMinter

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder nfTokenMinter(Optional<? extends Address> nfTokenMinter)
      Initializes the optional value nfTokenMinter to nfTokenMinter.
      Parameters:
      nfTokenMinter - The value for nfTokenMinter
      Returns:
      this builder for use in a chained invocation
    • ammId

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder ammId(Hash256 ammId)
      Initializes the optional value ammId to ammId.
      Parameters:
      ammId - The value for ammId
      Returns:
      this builder for chained invocation
    • ammId

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder ammId(Optional<? extends Hash256> ammId)
      Initializes the optional value ammId to ammId.
      Parameters:
      ammId - The value for ammId
      Returns:
      this builder for use in a chained invocation
    • walletLocator

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder walletLocator(String walletLocator)
      Initializes the optional value walletLocator to walletLocator.
      Parameters:
      walletLocator - The value for walletLocator
      Returns:
      this builder for chained invocation
    • walletLocator

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder walletLocator(Optional<String> walletLocator)
      Initializes the optional value walletLocator to walletLocator.
      Parameters:
      walletLocator - The value for walletLocator
      Returns:
      this builder for use in a chained invocation
    • index

      @CanIgnoreReturnValue public final ImmutableAccountRootObject.Builder index(Hash256 index)
      Initializes the value for the index attribute.
      Parameters:
      index - The value for index
      Returns:
      this builder for use in a chained invocation
    • build

      Returns:
      An immutable instance of AccountRootObject
      Throws:
      IllegalStateException - if any required attributes are missing