Interface DidObject

All Superinterfaces:
LedgerObject
All Known Implementing Classes:
ImmutableDidObject

@Beta @Immutable public interface DidObject extends LedgerObject
A DID ledger entry holds references to, or data associated with a single DID.

This interface will be marked Beta until the featureDID amendment is enabled on mainnet. Its API is subject to change.

  • Method Details

    • builder

      static ImmutableDidObject.Builder builder()
      Construct a DidObject builder.
      Returns:
      An ImmutableDidObject.Builder.
    • ledgerEntryType

      @Derived default LedgerObject.LedgerEntryType ledgerEntryType()
      The type of ledger object, which will always be "DID" in this case.
      Returns:
      Always returns LedgerObject.LedgerEntryType.DID.
    • flags

      @Derived default Flags flags()
      A bit-map of boolean flags. No flags are defined for DidObject, so this value is always 0.
      Returns:
      Always Flags.UNSET.
    • account

      Address account()
      The account that controls the DID.
      Returns:
      An Address.
    • didDocument

      Optional<DidDocument> didDocument()
      The W3C standard DID document associated with the DID. This field isn't checked for validity and is limited to a maximum length of 256 bytes.
      Returns:
      An optionally-present DidDocument.
    • data

      Optional<DidData> data()
      The public attestations of identity credentials associated with the DID. This field isn't checked for validity and is limited to a maximum length of 256 bytes.
      Returns:
      An optionally-present DidData.
    • uri

      The Universal Resource Identifier that points to the corresponding DID document or the data associated with the DID. This field can be an HTTP(S) URL or IPFS URI. This field isn't checked for validity and is limited to a maximum length of 256 bytes.
      Returns:
      An optionally-present DidUri.
    • ownerNode

      String ownerNode()
      A hint indicating which page of the sender's owner directory links to this object, in case the directory consists of multiple pages.

      Note: The object does not contain a direct link to the owner directory containing it, since that value can be derived from the Account.

      Returns:
      A String containing the owner node hint.
    • 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.
    • index

      Hash256 index()
      The unique ID of the DidObject.
      Returns:
      A Hash256 containing the ID.