Interface RippleStateObject

All Superinterfaces:
LedgerObject
All Known Implementing Classes:
ImmutableRippleStateObject

@Immutable public interface RippleStateObject extends LedgerObject
Represents the RippleState XRP Ledger Object.

There can only be one RippleStateObject per currency for any given pair of accounts. Since no account is privileged in the XRP Ledger, a RippleStateObject sorts account addresses numerically, to ensure a canonical form. Whichever address is numerically lower when decoded is deemed the "low account" and the other is the "high account". The net balance of the trust line is stored from the low account's perspective.

  • Method Details

    • builder

      Construct a builder for this class.
      Returns:
      An ImmutableRippleStateObject.Builder.
    • ledgerEntryType

      @Derived default LedgerObject.LedgerEntryType ledgerEntryType()
      The type of ledger object. In this case, this is always "RippleState".
      Returns:
      Always LedgerObject.LedgerEntryType.RIPPLE_STATE.
    • flags

      A set of boolean RippleStateFlags containing options enabled for this object.
      Returns:
      The RippleStateFlags for this object.
    • balance

      The balance of the trust line, from the perspective of the low account. A negative balance indicates that the low account has issued currency to the high account. The issuer in this is always set to the neutral value ACCOUNT_ONE.
      Returns:
      An IssuedCurrencyAmount containing the balance of this trust line.
    • lowLimit

      The limit that the low account has set on the trust line. The issuer is the address of the low account that set this limit.
      Returns:
      An IssuedCurrencyAmount containing the low account's limit on this trust line.
    • highLimit

      The limit that the high account has set on the trust line. The issuer is the address of the high account that set this limit.
      Returns:
      An IssuedCurrencyAmount containing the high account's limit on this trust line.
    • previousTransactionId

      Hash256 previousTransactionId()
      The identifying hash of the transaction that most recently modified this object.
      Returns:
      A Hash256 containing the previous transaction hash.
    • previousTransactionLedgerSequence

      com.google.common.primitives.UnsignedInteger previousTransactionLedgerSequence()
      The index of the ledger that contains the transaction that most recently modified this object.
      Returns:
      An UnsignedInteger representing the previous transaction ledger sequence.
    • lowNode

      Optional<String> lowNode()
      (Omitted in some historical ledgers) A hint indicating which page of the low account's owner directory links to this object, in case the directory consists of multiple pages.
      Returns:
      An Optional of type String containing the hint.
    • highNode

      Optional<String> highNode()
      (Omitted in some historical ledgers) A hint indicating which page of the high account's owner directory links to this object, in case the directory consists of multiple pages.
      Returns:
      An Optional of type String containing the hint.
    • lowQualityIn

      Optional<com.google.common.primitives.UnsignedInteger> lowQualityIn()
      The inbound quality set by the low account, as an integer in the implied ratio LowQualityOut:1,000,000,000. As a special case, the value 0 is equivalent to 1 billion, or face value.
      Returns:
      An Optional of type UnsignedInteger representing the low account's inbound quality.
    • lowQualityOut

      Optional<com.google.common.primitives.UnsignedInteger> lowQualityOut()
      The outbound quality set by the low account, as an integer in the implied ratio LowQualityOut:1,000,000,000. As a special case, the value 0 is equivalent to 1 billion, or face value.
      Returns:
      An Optional of type UnsignedInteger representing the low account's outbound quality.
    • highQualityIn

      Optional<com.google.common.primitives.UnsignedInteger> highQualityIn()
      The inbound quality set by the high account, as an integer in the implied ratio LowQualityOut:1,000,000,000. As a special case, the value 0 is equivalent to 1 billion, or face value.
      Returns:
      An Optional of type UnsignedInteger representing the high account's inbound quality.
    • highQualityOut

      Optional<com.google.common.primitives.UnsignedInteger> highQualityOut()
      The outbound quality set by the high account, as an integer in the implied ratio LowQualityOut:1,000,000,000. As a special case, the value 0 is equivalent to 1 billion, or face value.
      Returns:
      An Optional of type UnsignedInteger representing the high account's outbound quality.
    • index

      Hash256 index()
      Unique identifier for this RippleStateObject.
      Returns:
      A Hash256 containing the ID.