Documentation ¶
Index ¶
- Constants
- Variables
- func CalculateBlockBodyHash(txsRaw [][]string) ([]byte, error)
- func CustomTagSet() _cbor.TagSet
- func DetermineBlockType(data []byte) (uint, error)
- func DetermineTransactionType(data []byte) (uint, error)
- func EncodeCborList(data []cbor.RawMessage) ([]byte, error)
- func EncodeCborMap(data []AuxData) ([]byte, error)
- func EncodeCborTxSeq(data []uint) ([]byte, error)
- func ExtractBlockData(bodyHex string) ([]UTXOOutput, []RegisCert, []DeRegisCert, error)
- func GetBlockOutput(txBodies []BabbageTransactionBody) ([]UTXOOutput, []RegisCert, []DeRegisCert, error)
- func GetEncMode() (_cbor.EncMode, error)
- func GetListRegisCertPoolId(regisCerts []RegisCert) []string
- func GetListUnregisCertPoolId(deRegisCerts []DeRegisCert) []string
- func HashPair(l ed25519.PublicKey, r ed25519.PublicKey) ed25519.PublicKey
- func MkInputVrf(slot int64, eta0 []byte) []byte
- func NewEraMismatchErrorFromCbor(cborData []byte) (error, error)
- func NewGenericErrorFromCbor(cborData []byte) (error, error)
- func NewShelleyTxValidationErrorFromCbor(cborData []byte) (error, error)
- func NewTxSubmitErrorFromCbor(cborData []byte) (error, error)
- func VerifyBlock(block BlockHexCbor) (error, bool, string, uint64, uint64)
- func VerifyBlockBody(data string, blockBodyHash string) (bool, error)
- func VerifyKes(header *BabbageBlockHeader, slotsPerKesPeriod uint64) (bool, error)
- func VrfVerifyAndHash(publicKey []byte, proof []byte, msg []byte) ([]byte, error)
- type AddrKeyHash
- type Address
- type AllegraBlock
- type AllegraProtocolParameterUpdate
- type AllegraProtocolParameters
- type AllegraTransaction
- type AllegraTransactionBody
- type AlonzoBlock
- type AlonzoBlockHeader
- type AlonzoProtocolParameterUpdate
- type AlonzoProtocolParameters
- type AlonzoTransaction
- type AlonzoTransactionBody
- type AlonzoTransactionOutput
- type AlonzoTransactionWitnessSet
- type ApplyTxError
- type AssetFingerprint
- type AuxData
- type BabbageBlock
- type BabbageBlockHeader
- type BabbageProtocolParameterUpdate
- type BabbageProtocolParameters
- type BabbageTransaction
- type BabbageTransactionBody
- type BabbageTransactionOutput
- type BabbageTransactionWitnessSet
- type BadInputsUtxo
- type Blake2b224
- type Blake2b256
- type Block
- type BlockHeader
- type BlockHexCbor
- type ByronEpochBounaryBlockHeader
- type ByronEpochBoundaryBlock
- type ByronMainBlock
- type ByronMainBlockHeader
- type ByronTransaction
- type ByronTransactionInput
- type ByronTransactionOutput
- type Certificate
- type CertificateWrapper
- type CollateralContainsNonADA
- type ConwayBlock
- type ConwayBlockHeader
- type ConwayProtocolParameterUpdate
- type ConwayProtocolParameters
- type ConwayTransaction
- type ConwayTransactionBody
- type ConwayTransactionWitnessSet
- type DeRegisCert
- type Era
- type EraMismatch
- type ExUnitsTooBigUtxo
- type FeeTooSmallUtxo
- type GenericError
- type InputSetEmptyUtxo
- type InsufficientCollateral
- type IssuerVkey
- type MaryBlock
- type MaryBlockHeader
- type MaryProtocolParameterUpdate
- type MaryProtocolParameters
- type MaryTransaction
- type MaryTransactionBody
- type MaryTransactionOutput
- type MaryTransactionOutputValue
- type MaryTransactionWitnessSet
- type MaxTxSizeUtxo
- type MultiAssetTypeMint
- type MultiAssetTypeOutput
- type NewErrorFromCborFunc
- type NoCollateralInputs
- type OutputBootAddrAttrsTooBig
- type OutputTooBigUtxo
- type OutputTooSmallUtxo
- type OutsideForecast
- type OutsideValidityIntervalUtxo
- type PoolId
- type PoolRegistrationCertificate
- type PoolRelay
- type PoolRetirementCertificate
- type ProposalProcedure
- type RegisCert
- type ScriptsNotPaidUtxo
- type ShelleyBlock
- type ShelleyBlockHeader
- type ShelleyProtocolParameterUpdate
- type ShelleyProtocolParameters
- type ShelleyTransaction
- type ShelleyTransactionBody
- type ShelleyTransactionInput
- type ShelleyTransactionOutput
- type ShelleyTransactionWitnessSet
- type ShelleyTxValidationError
- type StakeDelegationCertificate
- type Sum0KesSig
- type SumXKesSig
- type TooManyCollateralInputs
- type Transaction
- type TransactionBody
- type TransactionInput
- type TransactionOutput
- type TriesToForgeADA
- type TxIn
- type TxOut
- type UTXOOutput
- type UTXOOutputToken
- type Utxo
- type UtxoFailure
- type UtxoFailureErrorBase
- type UtxosFailure
- type UtxowFailure
- type ValueNotConservedUtxo
- type VotingProcedure
- type VotingProcedures
- type WrongNetwork
- type WrongNetworkInTxBody
- type WrongNetworkWithdrawal
Constants ¶
const ( EraIdAllegra = allegra.EraIdAllegra BlockTypeAllegra = allegra.BlockTypeAllegra BlockHeaderTypeAllegra = allegra.BlockHeaderTypeAllegra TxTypeAllegra = allegra.TxTypeAllegra )
Allegra constants
const ( EraIdAlonzo = alonzo.EraIdAlonzo BlockTypeAlonzo = alonzo.BlockTypeAlonzo BlockHeaderTypeAlonzo = alonzo.BlockHeaderTypeAlonzo TxTypeAlonzo = alonzo.TxTypeAlonzo )
Alonzo constants
const ( EraIdBabbage = babbage.EraIdBabbage BlockTypeBabbage = babbage.BlockTypeBabbage BlockHeaderTypeBabbage = babbage.BlockHeaderTypeBabbage TxTypeBabbage = babbage.TxTypeBabbage )
Babbage constants
const ( EraIdByron = byron.EraIdByron BlockTypeByronEbb = byron.BlockTypeByronEbb BlockTypeByronMain = byron.BlockTypeByronMain BlockHeaderTypeByron = byron.BlockHeaderTypeByron TxTypeByron = byron.TxTypeByron )
Byron constants
const ( AddressTypeScriptNone = common.AddressTypeScriptNone AddressTypeKeyNone = common.AddressTypeKeyNone AddressTypeKeyKey = common.AddressTypeKeyKey )
const ( EraIdConway = conway.EraIdConway BlockTypeConway = conway.BlockTypeConway BlockHeaderTypeConway = conway.BlockHeaderTypeConway TxTypeConway = conway.TxTypeConway )
Conway constants
const ( ApplyTxErrorUtxowFailure = 0 UTXOWFailureUtxoFailure = 2 UtxoFailureFromAlonzo = 1 UtxoFailureBadInputsUtxo = 0 UtxoFailureOutsideValidityIntervalUtxo = 1 UtxoFailureMaxTxSizeUtxo = 2 UtxoFailureInputSetEmpty = 3 UtxoFailureFeeTooSmallUtxo = 4 UtxoFailureValueNotConservedUtxo = 5 UtxoFailureOutputTooSmallUtxo = 6 UtxoFailureUtxosFailure = 7 UtxoFailureWrongNetwork = 8 UtxoFailureWrongNetworkWithdrawal = 9 UtxoFailureOutputBootAddrAttrsTooBig = 10 UtxoFailureTriesToForgeAda = 11 UtxoFailureOutputTooBigUtxo = 12 UtxoFailureInsufficientCollateral = 13 UtxoFailureScriptsNotPaidUtxo = 14 UtxoFailureExUnitsTooBigUtxo = 15 UtxoFailureCollateralContainsNonAda = 16 UtxoFailureWrongNetworkInTxBody = 17 UtxoFailureOutsideForecast = 18 UtxoFailureTooManyCollateralInputs = 19 UtxoFailureNoCollateralInputs = 20 )
const ( EraIdMary = mary.EraIdMary BlockTypeMary = mary.BlockTypeMary BlockHeaderTypeMary = mary.BlockHeaderTypeMary TxTypeMary = mary.TxTypeMary )
Mary constants
const ( EraIdShelley = shelley.EraIdShelley BlockTypeShelley = shelley.BlockTypeShelley BlockHeaderTypeShelley = shelley.BlockHeaderTypeShelley TxTypeShelley = shelley.TxTypeShelley )
Shelley constants
const ( LOVELACE_TOKEN = "lovelace" BLOCK_BODY_HASH_ZERO_TX_HEX = "29571d16f081709b3c48651860077bebf9340abb3fc7133443c54f1f5a5edcf1" MAX_LIST_LENGTH_CBOR = 23 CBOR_TYPE_MAP = 0xa0 CBOR_TYPE_MAP_INDEF = 0xbf CBOR_BREAK_TAG = 0xff )
const ( SIGMA_SIZE = 64 PUBLIC_KEY_SIZE = 32 Sum0KesSig_SIZE = 64 )
const (
VRF_SUITE = 0x04 // ECVRF-ED25519-SHA512-Elligator2
)
Variables ¶
var ( NewAllegraBlockFromCbor = allegra.NewAllegraBlockFromCbor NewAllegraTransactionFromCbor = allegra.NewAllegraTransactionFromCbor NewAllegraTransactionBodyFromCbor = allegra.NewAllegraTransactionBodyFromCbor )
Allegra functions
var ( NewAlonzoBlockFromCbor = alonzo.NewAlonzoBlockFromCbor NewAlonzoTransactionFromCbor = alonzo.NewAlonzoTransactionFromCbor NewAlonzoTransactionBodyFromCbor = alonzo.NewAlonzoTransactionBodyFromCbor NewAlonzoTransactionOutputFromCbor = alonzo.NewAlonzoTransactionOutputFromCbor )
Alonzo functions
var ( NewBabbageBlockFromCbor = babbage.NewBabbageBlockFromCbor NewBabbageBlockHeaderFromCbor = babbage.NewBabbageBlockHeaderFromCbor NewBabbageTransactionFromCbor = babbage.NewBabbageTransactionFromCbor NewBabbageTransactionBodyFromCbor = babbage.NewBabbageTransactionBodyFromCbor NewBabbageTransactionOutputFromCbor = babbage.NewBabbageTransactionOutputFromCbor )
Babbage functions
var ( NewByronEpochBoundaryBlockFromCbor = byron.NewByronEpochBoundaryBlockFromCbor NewByronMainBlockFromCbor = byron.NewByronMainBlockFromCbor NewByronEpochBoundaryBlockHeaderFromCbor = byron.NewByronEpochBoundaryBlockHeaderFromCbor NewByronMainBlockHeaderFromCbor = byron.NewByronMainBlockHeaderFromCbor NewByronTransactionInput = byron.NewByronTransactionInput NewByronTransactionFromCbor = byron.NewByronTransactionFromCbor )
Byron functions
var ( NewAddress = common.NewAddress NewAddressFromParts = common.NewAddressFromParts )
var ( NewConwayBlockFromCbor = conway.NewConwayBlockFromCbor NewConwayBlockHeaderFromCbor = conway.NewConwayBlockHeaderFromCbor NewConwayTransactionFromCbor = conway.NewConwayTransactionFromCbor NewConwayTransactionBodyFromCbor = conway.NewConwayTransactionBodyFromCbor )
Conway functions
var ( NewMaryBlockFromCbor = mary.NewMaryBlockFromCbor NewMaryTransactionFromCbor = mary.NewMaryTransactionFromCbor NewMaryTransactionBodyFromCbor = mary.NewMaryTransactionBodyFromCbor NewMaryTransactionOutputFromCbor = mary.NewMaryTransactionOutputFromCbor )
Mary functions
var ( NewShelleyBlockFromCbor = shelley.NewShelleyBlockFromCbor NewShelleyBlockHeaderFromCbor = shelley.NewShelleyBlockHeaderFromCbor NewShelleyTransactionInput = shelley.NewShelleyTransactionInput NewShelleyTransactionFromCbor = shelley.NewShelleyTransactionFromCbor NewShelleyTransactionBodyFromCbor = shelley.NewShelleyTransactionBodyFromCbor NewShelleyTransactionOutputFromCbor = shelley.NewShelleyTransactionOutputFromCbor )
Shelley functions
var BlockHeaderToBlockTypeMap = map[uint]uint{ BlockHeaderTypeShelley: BlockTypeShelley, BlockHeaderTypeAllegra: BlockTypeAllegra, BlockHeaderTypeMary: BlockTypeMary, BlockHeaderTypeAlonzo: BlockTypeAlonzo, BlockHeaderTypeBabbage: BlockTypeBabbage, BlockHeaderTypeConway: BlockTypeConway, }
BlockHeaderToBlockTypeMap is a mapping of NtN chainsync block header types (era ID) to NtC block types
var BlockToBlockHeaderTypeMap = map[uint]uint{ BlockTypeShelley: BlockHeaderTypeShelley, BlockTypeAllegra: BlockHeaderTypeAllegra, BlockTypeMary: BlockHeaderTypeMary, BlockTypeAlonzo: BlockHeaderTypeAlonzo, BlockTypeBabbage: BlockHeaderTypeBabbage, BlockTypeConway: BlockHeaderTypeConway, }
BlockToBlockHeaderTypeMap is a mapping of NtC chainsync block types to NtN block header types (era ID)
var EraInvalid = common.EraInvalid
Functions ¶
func CalculateBlockBodyHash ¶ added in v0.84.0
func CustomTagSet ¶ added in v0.95.0
func DetermineBlockType ¶ added in v0.67.0
func DetermineTransactionType ¶ added in v0.55.0
func EncodeCborList ¶ added in v0.95.0
func EncodeCborList(data []cbor.RawMessage) ([]byte, error)
func EncodeCborMap ¶ added in v0.95.0
EncodeCborMap manual build aux bytes data
func EncodeCborTxSeq ¶ added in v0.95.0
func ExtractBlockData ¶ added in v0.84.0
func ExtractBlockData( bodyHex string, ) ([]UTXOOutput, []RegisCert, []DeRegisCert, error)
func GetBlockOutput ¶ added in v0.84.0
func GetBlockOutput( txBodies []BabbageTransactionBody, ) ([]UTXOOutput, []RegisCert, []DeRegisCert, error)
func GetEncMode ¶ added in v0.95.0
func GetListRegisCertPoolId ¶ added in v0.84.0
func GetListUnregisCertPoolId ¶ added in v0.84.0
func GetListUnregisCertPoolId(deRegisCerts []DeRegisCert) []string
func MkInputVrf ¶ added in v0.84.0
func NewGenericErrorFromCbor ¶
func NewTxSubmitErrorFromCbor ¶
Helper function to try to parse CBOR as various error types
func VerifyBlock ¶ added in v0.84.0
func VerifyBlockBody ¶ added in v0.84.0
Types ¶
type AddrKeyHash ¶ added in v0.84.0
type AddrKeyHash = common.AddrKeyHash
type AllegraProtocolParameterUpdate ¶ added in v0.79.0
type AllegraProtocolParameterUpdate = allegra.AllegraProtocolParameterUpdate
type AllegraProtocolParameters ¶ added in v0.79.0
type AllegraProtocolParameters = allegra.AllegraProtocolParameters
type AllegraTransaction ¶
type AllegraTransaction = allegra.AllegraTransaction
type AllegraTransactionBody ¶
type AllegraTransactionBody = allegra.AllegraTransactionBody
type AlonzoBlockHeader ¶
type AlonzoBlockHeader = alonzo.AlonzoBlockHeader
type AlonzoProtocolParameterUpdate ¶ added in v0.80.0
type AlonzoProtocolParameterUpdate = alonzo.AlonzoProtocolParameterUpdate
type AlonzoProtocolParameters ¶ added in v0.80.0
type AlonzoProtocolParameters = alonzo.AlonzoProtocolParameters
type AlonzoTransaction ¶
type AlonzoTransaction = alonzo.AlonzoTransaction
type AlonzoTransactionBody ¶
type AlonzoTransactionBody = alonzo.AlonzoTransactionBody
type AlonzoTransactionOutput ¶
type AlonzoTransactionOutput = alonzo.AlonzoTransactionOutput
type AlonzoTransactionWitnessSet ¶
type AlonzoTransactionWitnessSet = alonzo.AlonzoTransactionWitnessSet
type ApplyTxError ¶
type ApplyTxError struct { cbor.StructAsArray Failures []error }
func (*ApplyTxError) Error ¶
func (e *ApplyTxError) Error() string
func (*ApplyTxError) UnmarshalCBOR ¶
func (e *ApplyTxError) UnmarshalCBOR(data []byte) error
type AssetFingerprint ¶ added in v0.44.0
type AssetFingerprint = common.AssetFingerprint
func NewAssetFingerprint ¶ added in v0.44.0
func NewAssetFingerprint(policyId []byte, assetName []byte) AssetFingerprint
type BabbageBlockHeader ¶
type BabbageBlockHeader = babbage.BabbageBlockHeader
type BabbageProtocolParameterUpdate ¶ added in v0.77.0
type BabbageProtocolParameterUpdate = babbage.BabbageProtocolParameterUpdate
type BabbageProtocolParameters ¶ added in v0.77.0
type BabbageProtocolParameters = babbage.BabbageProtocolParameters
type BabbageTransaction ¶
type BabbageTransaction = babbage.BabbageTransaction
type BabbageTransactionBody ¶
type BabbageTransactionBody = babbage.BabbageTransactionBody
func GetTxBodies ¶ added in v0.84.0
func GetTxBodies(txsRaw [][]string) ([]BabbageTransactionBody, error)
type BabbageTransactionOutput ¶
type BabbageTransactionOutput = babbage.BabbageTransactionOutput
type BabbageTransactionWitnessSet ¶
type BabbageTransactionWitnessSet = babbage.BabbageTransactionWitnessSet
type BadInputsUtxo ¶
type BadInputsUtxo struct { UtxoFailureErrorBase Inputs []TxIn }
func (*BadInputsUtxo) Error ¶
func (e *BadInputsUtxo) Error() string
type Blake2b224 ¶
type Blake2b224 = common.Blake2b224
Hash types
func NewBlake2b224 ¶ added in v0.44.0
func NewBlake2b224(data []byte) Blake2b224
type Blake2b256 ¶
type Blake2b256 = common.Blake2b256
func NewBlake2b256 ¶ added in v0.44.0
func NewBlake2b256(data []byte) Blake2b256
type Block ¶
type Block interface { BlockHeader Type() int Transactions() []Transaction Utxorpc() *utxorpc.Block }
type BlockHeader ¶
type BlockHeader interface { Hash() string BlockNumber() uint64 SlotNumber() uint64 IssuerVkey() IssuerVkey BlockBodySize() uint64 Era() Era Cbor() []byte }
func NewBlockHeaderFromCbor ¶
func NewBlockHeaderFromCbor(blockType uint, data []byte) (BlockHeader, error)
XXX: should this take the block header type instead?
type BlockHexCbor ¶ added in v0.84.0
type ByronEpochBounaryBlockHeader ¶ added in v0.93.0
type ByronEpochBounaryBlockHeader = byron.ByronEpochBoundaryBlockHeader
type ByronEpochBoundaryBlock ¶
type ByronEpochBoundaryBlock = byron.ByronEpochBoundaryBlock
Byron types
type ByronMainBlock ¶
type ByronMainBlock = byron.ByronMainBlock
type ByronMainBlockHeader ¶
type ByronMainBlockHeader = byron.ByronMainBlockHeader
type ByronTransaction ¶
type ByronTransaction = byron.ByronTransaction
type ByronTransactionInput ¶ added in v0.77.0
type ByronTransactionInput = byron.ByronTransactionInput
type ByronTransactionOutput ¶ added in v0.77.0
type ByronTransactionOutput = byron.ByronTransactionOutput
type CertificateWrapper ¶ added in v0.84.0
type CertificateWrapper = common.CertificateWrapper
type CollateralContainsNonADA ¶
type CollateralContainsNonADA struct { UtxoFailureErrorBase // TODO: determine content/structure of this value Value cbor.Value }
func (*CollateralContainsNonADA) Error ¶
func (e *CollateralContainsNonADA) Error() string
type ConwayBlockHeader ¶ added in v0.60.0
type ConwayBlockHeader = conway.ConwayBlockHeader
type ConwayProtocolParameterUpdate ¶ added in v0.91.0
type ConwayProtocolParameterUpdate = conway.ConwayProtocolParameterUpdate
type ConwayProtocolParameters ¶ added in v0.91.0
type ConwayProtocolParameters = conway.ConwayProtocolParameters
type ConwayTransaction ¶ added in v0.60.0
type ConwayTransaction = conway.ConwayTransaction
type ConwayTransactionBody ¶ added in v0.60.0
type ConwayTransactionBody = conway.ConwayTransactionBody
type ConwayTransactionWitnessSet ¶ added in v0.91.0
type ConwayTransactionWitnessSet = conway.ConwayTransactionWitnessSet
type DeRegisCert ¶ added in v0.84.0
type EraMismatch ¶
type EraMismatch struct { cbor.StructAsArray LedgerEra uint8 OtherEra uint8 }
func (*EraMismatch) Error ¶
func (e *EraMismatch) Error() string
type ExUnitsTooBigUtxo ¶
type ExUnitsTooBigUtxo struct { UtxoFailureErrorBase MaxAllowed int Supplied int }
func (*ExUnitsTooBigUtxo) Error ¶
func (e *ExUnitsTooBigUtxo) Error() string
type FeeTooSmallUtxo ¶
type FeeTooSmallUtxo struct { UtxoFailureErrorBase MinimumFee uint64 SuppliedFee uint64 }
func (*FeeTooSmallUtxo) Error ¶
func (e *FeeTooSmallUtxo) Error() string
type GenericError ¶
type GenericError struct { Value interface{} Cbor []byte }
func (*GenericError) Error ¶
func (e *GenericError) Error() string
func (*GenericError) UnmarshalCBOR ¶
func (e *GenericError) UnmarshalCBOR(data []byte) error
type InputSetEmptyUtxo ¶
type InputSetEmptyUtxo struct {
UtxoFailureErrorBase
}
func (*InputSetEmptyUtxo) Error ¶
func (e *InputSetEmptyUtxo) Error() string
type InsufficientCollateral ¶
type InsufficientCollateral struct { UtxoFailureErrorBase BalanceComputed uint64 RequiredCollateral uint64 }
func (*InsufficientCollateral) Error ¶
func (e *InsufficientCollateral) Error() string
type MaryBlockHeader ¶
type MaryBlockHeader = mary.MaryBlockHeader
type MaryProtocolParameterUpdate ¶ added in v0.80.0
type MaryProtocolParameterUpdate = mary.MaryProtocolParameterUpdate
type MaryProtocolParameters ¶ added in v0.80.0
type MaryProtocolParameters = mary.MaryProtocolParameters
type MaryTransaction ¶
type MaryTransaction = mary.MaryTransaction
type MaryTransactionBody ¶
type MaryTransactionBody = mary.MaryTransactionBody
type MaryTransactionOutput ¶
type MaryTransactionOutput = mary.MaryTransactionOutput
type MaryTransactionOutputValue ¶ added in v0.42.0
type MaryTransactionOutputValue = mary.MaryTransactionOutputValue
type MaryTransactionWitnessSet ¶ added in v0.80.0
type MaryTransactionWitnessSet = mary.MaryTransactionWitnessSet
type MaxTxSizeUtxo ¶
type MaxTxSizeUtxo struct { UtxoFailureErrorBase ActualSize int MaxSize int }
func (*MaxTxSizeUtxo) Error ¶
func (e *MaxTxSizeUtxo) Error() string
type MultiAssetTypeMint ¶ added in v0.44.0
type MultiAssetTypeMint = common.MultiAssetTypeMint
Assets
type MultiAssetTypeOutput ¶ added in v0.44.0
type MultiAssetTypeOutput = common.MultiAssetTypeOutput
type NewErrorFromCborFunc ¶
Helper type to make the code a little cleaner
type NoCollateralInputs ¶
type NoCollateralInputs struct {
UtxoFailureErrorBase
}
func (*NoCollateralInputs) Error ¶
func (e *NoCollateralInputs) Error() string
type OutputBootAddrAttrsTooBig ¶
type OutputBootAddrAttrsTooBig struct { UtxoFailureErrorBase Outputs []TxOut }
func (*OutputBootAddrAttrsTooBig) Error ¶
func (e *OutputBootAddrAttrsTooBig) Error() string
type OutputTooBigUtxo ¶
type OutputTooBigUtxo struct { UtxoFailureErrorBase Outputs []struct { ActualSize int MaxSize int Output TxOut } }
func (*OutputTooBigUtxo) Error ¶
func (e *OutputTooBigUtxo) Error() string
type OutputTooSmallUtxo ¶
type OutputTooSmallUtxo struct { UtxoFailureErrorBase Outputs []TxOut }
func (*OutputTooSmallUtxo) Error ¶
func (e *OutputTooSmallUtxo) Error() string
type OutsideForecast ¶
type OutsideForecast struct { UtxoFailureErrorBase Slot uint32 }
func (*OutsideForecast) Error ¶
func (e *OutsideForecast) Error() string
type OutsideValidityIntervalUtxo ¶
type OutsideValidityIntervalUtxo struct { UtxoFailureErrorBase ValidityInterval cbor.Value Slot uint32 }
func (*OutsideValidityIntervalUtxo) Error ¶
func (e *OutsideValidityIntervalUtxo) Error() string
type PoolId ¶ added in v0.77.0
func NewPoolIdFromBech32 ¶ added in v0.77.0
type PoolRegistrationCertificate ¶ added in v0.84.0
type PoolRegistrationCertificate = common.PoolRegistrationCertificate
type PoolRetirementCertificate ¶ added in v0.84.0
type PoolRetirementCertificate = common.PoolRetirementCertificate
type ProposalProcedure ¶ added in v0.85.0
type ProposalProcedure = common.ProposalProcedure
type ScriptsNotPaidUtxo ¶
type ScriptsNotPaidUtxo struct { UtxoFailureErrorBase // TODO: determine content/structure of this value Value cbor.Value }
func (*ScriptsNotPaidUtxo) Error ¶
func (e *ScriptsNotPaidUtxo) Error() string
type ShelleyBlockHeader ¶
type ShelleyBlockHeader = shelley.ShelleyBlockHeader
type ShelleyProtocolParameterUpdate ¶ added in v0.79.0
type ShelleyProtocolParameterUpdate = shelley.ShelleyProtocolParameterUpdate
type ShelleyProtocolParameters ¶ added in v0.79.0
type ShelleyProtocolParameters = shelley.ShelleyProtocolParameters
type ShelleyTransaction ¶
type ShelleyTransaction = shelley.ShelleyTransaction
type ShelleyTransactionBody ¶
type ShelleyTransactionBody = shelley.ShelleyTransactionBody
type ShelleyTransactionInput ¶
type ShelleyTransactionInput = shelley.ShelleyTransactionInput
type ShelleyTransactionOutput ¶
type ShelleyTransactionOutput = shelley.ShelleyTransactionOutput
type ShelleyTransactionWitnessSet ¶
type ShelleyTransactionWitnessSet = shelley.ShelleyTransactionWitnessSet
type ShelleyTxValidationError ¶
type ShelleyTxValidationError struct { Era uint8 Err ApplyTxError }
func (*ShelleyTxValidationError) Error ¶
func (e *ShelleyTxValidationError) Error() string
func (*ShelleyTxValidationError) UnmarshalCBOR ¶
func (e *ShelleyTxValidationError) UnmarshalCBOR(data []byte) error
type StakeDelegationCertificate ¶ added in v0.84.0
type StakeDelegationCertificate = common.StakeDelegationCertificate
type Sum0KesSig ¶ added in v0.84.0
type Sum0KesSig []byte
func Sum0KesSigFromByte ¶ added in v0.84.0
func Sum0KesSigFromByte(sigBytes []byte) Sum0KesSig
type SumXKesSig ¶ added in v0.84.0
type SumXKesSig struct { Depth uint64 Sigma interface{} LeftHandSidePublicKey ed25519.PublicKey RightHandSidePublicKey ed25519.PublicKey }
func NewSumKesFromByte ¶ added in v0.84.0
func NewSumKesFromByte(depth uint64, fromByte []byte) SumXKesSig
type TooManyCollateralInputs ¶
type TooManyCollateralInputs struct { UtxoFailureErrorBase MaxAllowed int Supplied int }
func (*TooManyCollateralInputs) Error ¶
func (e *TooManyCollateralInputs) Error() string
type Transaction ¶ added in v0.46.0
type Transaction = common.Transaction
Compatibility aliases
func NewTransactionFromCbor ¶
func NewTransactionFromCbor(txType uint, data []byte) (Transaction, error)
type TransactionBody ¶
type TransactionBody = common.TransactionBody
func NewTransactionBodyFromCbor ¶
func NewTransactionBodyFromCbor( txType uint, data []byte, ) (TransactionBody, error)
type TransactionInput ¶ added in v0.43.0
type TransactionInput = common.TransactionInput
type TransactionOutput ¶ added in v0.43.0
type TransactionOutput = common.TransactionOutput
func NewTransactionOutputFromCbor ¶ added in v0.69.0
func NewTransactionOutputFromCbor(data []byte) (TransactionOutput, error)
NewTransactionOutputFromCbor attempts to parse the provided arbitrary CBOR data as a transaction output from each of the eras, returning the first one that we can successfully decode
type TriesToForgeADA ¶
type TriesToForgeADA struct {
UtxoFailureErrorBase
}
func (*TriesToForgeADA) Error ¶
func (e *TriesToForgeADA) Error() string
type TxIn ¶
type TxIn struct { cbor.StructAsArray Utxo cbor.ByteString TxIx uint8 }
type UTXOOutput ¶ added in v0.84.0
type UTXOOutput struct { Flag int TxHash string OutputIndex string Tokens []UTXOOutputToken DatumHex string // contains filtered or unexported fields }
type UTXOOutputToken ¶ added in v0.84.0
type UTXOOutputToken struct { Flag int TokenAssetName string TokenValue string // contains filtered or unexported fields }
func ExtractTokens ¶ added in v0.84.0
func ExtractTokens(output TransactionOutput) ([]UTXOOutputToken, error)
type UtxoFailure ¶
type UtxoFailure struct { cbor.StructAsArray Era uint8 Err error }
func (*UtxoFailure) Error ¶
func (e *UtxoFailure) Error() string
func (*UtxoFailure) UnmarshalCBOR ¶
func (e *UtxoFailure) UnmarshalCBOR(data []byte) error
type UtxoFailureErrorBase ¶
type UtxoFailureErrorBase struct { cbor.StructAsArray Type uint8 }
type UtxosFailure ¶
type UtxosFailure struct { UtxoFailureErrorBase Err GenericError }
func (*UtxosFailure) Error ¶
func (e *UtxosFailure) Error() string
type UtxowFailure ¶
type UtxowFailure struct { cbor.StructAsArray Err error }
func (*UtxowFailure) Error ¶
func (e *UtxowFailure) Error() string
func (*UtxowFailure) UnmarshalCBOR ¶
func (e *UtxowFailure) UnmarshalCBOR(data []byte) error
type ValueNotConservedUtxo ¶
type ValueNotConservedUtxo struct { UtxoFailureErrorBase Consumed uint64 Produced uint64 }
func (*ValueNotConservedUtxo) Error ¶
func (e *ValueNotConservedUtxo) Error() string
type VotingProcedure ¶ added in v0.85.0
type VotingProcedure = common.VotingProcedure
Governance types
type VotingProcedures ¶ added in v0.85.0
type VotingProcedures = common.VotingProcedures
type WrongNetwork ¶
type WrongNetwork struct { UtxoFailureErrorBase ExpectedNetworkId int Addresses cbor.Value }
func (*WrongNetwork) Error ¶
func (e *WrongNetwork) Error() string
type WrongNetworkInTxBody ¶
type WrongNetworkInTxBody struct { UtxoFailureErrorBase ActualNetworkId int TransactionNetworkId int }
func (*WrongNetworkInTxBody) Error ¶
func (e *WrongNetworkInTxBody) Error() string
type WrongNetworkWithdrawal ¶
type WrongNetworkWithdrawal struct { UtxoFailureErrorBase ExpectedNetworkId int RewardAccounts cbor.Value }
func (*WrongNetworkWithdrawal) Error ¶
func (e *WrongNetworkWithdrawal) Error() string