Initializes a new instance of the Datum class.
REMARK: A datum must be either a hash or the inlined data, but not both.
Optional
dataHash: Hash32ByteBase16The hash of the Datum.
Optional
inlineData: Serialization.PlutusDataThe data being included directly within the transaction output.
Private
#dataPrivate
#datumPrivate
#inlinePrivate
#originalGets this datum as a Datum hash.
a DatumHash if the Datum can be cast, otherwise, undefined.
Gets this datum as PlutusData.
a PlutusData instance if the Datum can be cast, otherwise, undefined.
Gets the datum kind.
the datum kind.
Creates a Core Datum object from the current Datum object.
The Core Datum object.
Static
fromDeserializes the Datum from a CBOR byte array.
The new Datum instance.
The CBOR encoded Datum object.
Static
fromCreates a Datum object from the given Core Datum object.
core Datum object.
Static
newGets a Datum instance from a Datum hash.
The Datum hash to 'cast' to Datum.
Static
newGets a Datum instance from Inline Data.
The PlutusData to 'cast' to Datum.
Generated using TypeDoc
Represents a piece of data attached to a UTxO that a Plutus script can read when the UTxO is being spent. Essentially, the Datum acts as a state for that UTxO, allowing Plutus scripts to perform more complex logic based on this stored state.