ouroboros-consensus-cardano-0.20.0.0: The instantation of the Ouroboros consensus layer used by Cardano
Safe HaskellSafe-Inferred
LanguageHaskell2010

Ouroboros.Consensus.Cardano

Synopsis

The block type of the Cardano block chain

type CardanoBlock c = HardForkBlock (CardanoEras c) Source #

The Cardano block.

Thanks to the pattern synonyms, you can treat this as a sum type with constructors BlockByron, BlockShelley, etc.

f :: CardanoBlock c -> _
f (BlockByron   b) = _
f (BlockShelley s) = _
f (BlockAllegra a) = _
f (BlockMary    m) = _
f (BlockAlonzo  m) = _

Supported protocols

Abstract over the various protocols

data CardanoHardForkTrigger blk Source #

When to trigger a hard fork to a Cardano era.

Constructors

CardanoTriggerHardForkAtDefaultVersion

Trigger the hard fork when the ledger protocol version is updated to the default for that era (eraProtVerLow @(ShelleyBlockLedgerEra blk)). Also see TriggerHardForkAtVersion.

CardanoTriggerHardForkAtEpoch EpochNo

Trigger the hard fork at the given epoch. For testing only. Also see TriggerHardForkAtEpoch.

Instances

Instances details
Show (CardanoHardForkTrigger blk) Source # 
Instance details

Defined in Ouroboros.Consensus.Cardano.Node