Helios API/ API Reference/ Classes/

HashedDatum

Inside helios this type is named OutputDatum::Hash in order to distinguish it from the user defined Datum, but outside helios scripts there isn't much sense to keep using the name 'OutputDatum' instead of Datum

Hierarchy

Index

Constructors

constructor

new HashedDatum(hash, origData?)

Parameters

NameType
hashDatumHash
origData?null | UplcData

Overrides

Datum.constructor

Accessors

data

get data(): null | UplcData

Returns

null | UplcData

Inherited from

Datum.data

hash

get hash(): DatumHash

Returns

DatumHash

Inherited from

Datum.hash

Methods

dump

dump(): any

Returns

any

Inherited from

Datum.dump

isHashed

isHashed(): boolean

Returns

boolean

Inherited from

Datum.isHashed

isInline

isInline(): boolean

Returns

boolean

Inherited from

Datum.isInline

toCbor

toCbor(): number[]

Returns

number[]

Inherited from

Datum.toCbor

toCborHex

toCborHex(): string

Returns

string

Inherited from

Datum.toCborHex

toData

toData(): ConstrData

Returns

ConstrData

Inherited from

Datum.toData

fromCbor

Static fromCbor(bytes): Datum

Parameters

NameType
bytesnumber[]

Returns

Datum

Inherited from

Datum.fromCbor

fromData

Static fromData(data): HashedDatum

Constructs a HashedDatum. The input data is hashed internally.

Parameters

NameType
dataUplcData

Returns

HashedDatum

fromUplcData

Static fromUplcData(data): null | Datum

Parameters

NameType
dataUplcData

Returns

null | Datum

Inherited from

Datum.fromUplcData

hashed

Static hashed(data): Datum

Constructs a HashedDatum. The input data is hashed internally.

Parameters

Returns

Datum

Inherited from

Datum.hashed

inline

Static inline(data): Datum

Parameters

Returns

Datum

Inherited from

Datum.inline