Documentation ¶
Index ¶
- Variables
- func HashDatum(d cbor.Marshaler) serialization.DatumHash
- func PlutusDataHash(pd *PlutusData) serialization.DatumHash
- func PlutusScriptHash(script ScriptHashable) serialization.ScriptHash
- func ToCbor(x interface{}) string
- type CM
- type CborMap
- type CostModels
- type CostView
- type Datum
- type DatumOption
- type DatumType
- type PlutusData
- type PlutusDefArray
- type PlutusIndefArray
- type PlutusList
- type PlutusType
- type PlutusV1Script
- type PlutusV2Script
- type RawPlutusData
- type ScriptHashable
- type ScriptRef
Constants ¶
This section is empty.
Variables ¶
View Source
var COST_MODELSV1 = map[serialization.CustomBytes]cbor.Marshaler{{Value: "00"}: PLUTUSV1COSTMODEL}
View Source
var COST_MODELSV2 = map[int]cbor.Marshaler{1: PLUTUSV2COSTMODEL}
View Source
var PLUTUSV1COSTMODEL = CM{}/* 166 elements not displayed */
View Source
var PLUTUSV2COSTMODEL = CostView{}/* 175 elements not displayed */
Functions ¶
func HashDatum ¶
func HashDatum(d cbor.Marshaler) serialization.DatumHash
func PlutusDataHash ¶
func PlutusDataHash(pd *PlutusData) serialization.DatumHash
func PlutusScriptHash ¶
func PlutusScriptHash(script ScriptHashable) serialization.ScriptHash
Types ¶
type CborMap ¶
type CborMap struct {
Contents *map[serialization.CustomBytes]PlutusData
}
func (*CborMap) MarshalCBOR ¶
func (*CborMap) UnmarshalCBOR ¶
type CostModels ¶
type CostModels map[serialization.CustomBytes]CM
type CostView ¶
func (CostView) MarshalCBOR ¶
type Datum ¶
type Datum struct { PlutusDataType PlutusType TagNr uint64 Value any }
func (Datum) MarshalCBOR ¶
func (*Datum) ToPlutusData ¶
func (pd *Datum) ToPlutusData() PlutusData
func (*Datum) UnmarshalCBOR ¶
type DatumOption ¶
type DatumOption struct { DatumType DatumType Hash []byte Inline *PlutusData // contains filtered or unexported fields }
func DatumOptionHash ¶
func DatumOptionHash(hash []byte) DatumOption
func DatumOptionInline ¶
func DatumOptionInline(pd *PlutusData) DatumOption
func (DatumOption) MarshalCBOR ¶
func (d DatumOption) MarshalCBOR() ([]byte, error)
func (*DatumOption) UnmarshalCBOR ¶
func (d *DatumOption) UnmarshalCBOR(b []byte) error
type PlutusData ¶
type PlutusData struct { PlutusDataType PlutusType TagNr uint64 Value any }
func (*PlutusData) Clone ¶
func (pd *PlutusData) Clone() PlutusData
func (*PlutusData) Equal ¶
func (pd *PlutusData) Equal(other PlutusData) bool
func (*PlutusData) MarshalCBOR ¶
func (pd *PlutusData) MarshalCBOR() ([]uint8, error)
func (*PlutusData) ToDatum ¶
func (pd *PlutusData) ToDatum() Datum
func (*PlutusData) UnmarshalCBOR ¶
func (pd *PlutusData) UnmarshalCBOR(value []uint8) error
func (*PlutusData) UnmarshalJSON ¶
func (pd *PlutusData) UnmarshalJSON(value []byte) error
type PlutusDefArray ¶
type PlutusDefArray []PlutusData
func (PlutusDefArray) Len ¶
func (pia PlutusDefArray) Len() int
type PlutusIndefArray ¶
type PlutusIndefArray []PlutusData
func (*PlutusIndefArray) Clone ¶
func (pia *PlutusIndefArray) Clone() PlutusIndefArray
func (PlutusIndefArray) Len ¶
func (pia PlutusIndefArray) Len() int
func (PlutusIndefArray) MarshalCBOR ¶
func (pia PlutusIndefArray) MarshalCBOR() ([]uint8, error)
type PlutusList ¶
type PlutusList interface {
Len() int
}
type PlutusType ¶
type PlutusType int
const ( PlutusArray PlutusType = iota PlutusMap PlutusInt PlutusBytes PlutusShortArray )
type PlutusV1Script ¶
type PlutusV1Script []byte
func (PlutusV1Script) Hash ¶
func (ps PlutusV1Script) Hash() serialization.ScriptHash
type PlutusV2Script ¶
type PlutusV2Script []byte
func (PlutusV2Script) Hash ¶
func (ps PlutusV2Script) Hash() serialization.ScriptHash
type RawPlutusData ¶
type RawPlutusData struct { }
type ScriptHashable ¶
type ScriptHashable interface {
Hash() serialization.ScriptHash
}
Click to show internal directories.
Click to hide internal directories.