cardano-api-1.36.0: The cardano api
Safe HaskellSafe-Inferred
LanguageHaskell2010

Cardano.Api.InMode

Description

Transactions in the context of a consensus mode, and other types used in the transaction submission protocol.

Synopsis

Transaction in a consensus mode

data TxInMode mode where Source #

A Tx in one of the eras supported by a given protocol mode.

For multi-era modes such as the CardanoMode this type is a sum of the different transaction types for all the eras. It is used in the LocalTxSubmission protocol.

Constructors

TxInModeTx era → EraInMode era mode → TxInMode mode

Everything we consider a normal transaction.

TxInByronSpecial ∷ GenTx ByronBlock → EraInMode ByronEra mode → TxInMode mode

Byron has various things we can post to the chain which are not actually transactions. This covers: update proposals, votes and delegation certs.

Instances

Instances details
Show (TxInMode mode) Source # 
Instance details

Defined in Cardano.Api.InMode

Methods

showsPrecIntTxInMode mode → ShowS Source #

showTxInMode mode → String Source #

showList ∷ [TxInMode mode] → ShowS Source #

fromConsensusGenTxConsensusBlockForMode mode ~ block ⇒ ConsensusMode mode → GenTx block → TxInMode mode Source #

toConsensusGenTxConsensusBlockForMode mode ~ block ⇒ TxInMode mode → GenTx block Source #

Transaction id in a consensus mode

data TxIdInMode mode where Source #

A TxId in one of the eras supported by a given protocol mode.

For multi-era modes such as the CardanoMode this type is a sum of the different transaction types for all the eras. It is used in the LocalTxMonitoring protocol.

Constructors

TxIdInModeTxIdEraInMode era mode → TxIdInMode mode 

toConsensusTxIdConsensusBlockForMode mode ~ block ⇒ TxIdInMode mode → TxId (GenTx block) Source #

Transaction validation errors

data TxValidationError era where Source #

The transaction validations errors that can occur from trying to submit a transaction to a local node. The errors are specific to an era.

Constructors

ByronTxValidationError ∷ ApplyTxErr ByronBlock → TxValidationError ByronEra 
ShelleyTxValidationErrorShelleyBasedEra era → ApplyTxErr (ShelleyBlock (ConsensusProtocol era) (ShelleyLedgerEra era)) → TxValidationError era 

Instances

Instances details
Show (TxValidationError era) Source # 
Instance details

Defined in Cardano.Api.InMode

data TxValidationErrorInMode mode where Source #

A TxValidationError in one of the eras supported by a given protocol mode.

This is used in the LocalStateQuery protocol.

Instances

Instances details
Show (TxValidationErrorInMode mode) Source # 
Instance details

Defined in Cardano.Api.InMode

fromConsensusApplyTxErrConsensusBlockForMode mode ~ block ⇒ LedgerSupportsProtocol (ShelleyBlock (TPraos StandardCrypto) (ShelleyEra StandardCrypto)) ⇒ ConsensusMode mode → ApplyTxErr block → TxValidationErrorInMode mode Source #