Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- type CardanoBlock c = HardForkBlock (CardanoEras c)
- type ProtocolByron = HardForkProtocol '[ByronBlock]
- type ProtocolCardano = HardForkProtocol '[ByronBlock, ShelleyBlock (TPraos StandardCrypto) StandardShelley, ShelleyBlock (TPraos StandardCrypto) StandardAllegra, ShelleyBlock (TPraos StandardCrypto) StandardMary, ShelleyBlock (TPraos StandardCrypto) StandardAlonzo, ShelleyBlock (Praos StandardCrypto) StandardBabbage, ShelleyBlock (Praos StandardCrypto) StandardConway]
- type ProtocolShelley = HardForkProtocol '[ShelleyBlock (TPraos StandardCrypto) StandardShelley]
- data CardanoHardForkTrigger blk
- newtype CardanoHardForkTriggers where
- CardanoHardForkTriggers { }
- pattern CardanoHardForkTriggers' ∷ c ~ StandardCrypto ⇒ CardanoHardForkTrigger (ShelleyBlock (TPraos c) (ShelleyEra c)) → CardanoHardForkTrigger (ShelleyBlock (TPraos c) (AllegraEra c)) → CardanoHardForkTrigger (ShelleyBlock (TPraos c) (MaryEra c)) → CardanoHardForkTrigger (ShelleyBlock (TPraos c) (AlonzoEra c)) → CardanoHardForkTrigger (ShelleyBlock (Praos c) (BabbageEra c)) → CardanoHardForkTrigger (ShelleyBlock (Praos c) (ConwayEra c)) → CardanoHardForkTriggers
- module Ouroboros.Consensus.Shelley.Node
- module Ouroboros.Consensus.Byron.Node
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
type ProtocolByron = HardForkProtocol '[ByronBlock] Source #
type ProtocolCardano = HardForkProtocol '[ByronBlock, ShelleyBlock (TPraos StandardCrypto) StandardShelley, ShelleyBlock (TPraos StandardCrypto) StandardAllegra, ShelleyBlock (TPraos StandardCrypto) StandardMary, ShelleyBlock (TPraos StandardCrypto) StandardAlonzo, ShelleyBlock (Praos StandardCrypto) StandardBabbage, ShelleyBlock (Praos StandardCrypto) StandardConway] Source #
type ProtocolShelley = HardForkProtocol '[ShelleyBlock (TPraos StandardCrypto) StandardShelley] Source #
Abstract over the various protocols
data CardanoHardForkTrigger blk Source #
When to trigger a hard fork to a Cardano era.
CardanoTriggerHardForkAtDefaultVersion | Trigger the hard fork when the ledger protocol version is updated to
the default for that era ( |
CardanoTriggerHardForkAtEpoch EpochNo | Trigger the hard fork at the given epoch. For testing only. Also see
|
Instances
Show (CardanoHardForkTrigger blk) Source # | |
Defined in Ouroboros.Consensus.Cardano.Node showsPrec ∷ Int → CardanoHardForkTrigger blk → ShowS # show ∷ CardanoHardForkTrigger blk → String # showList ∷ [CardanoHardForkTrigger blk] → ShowS # |
newtype CardanoHardForkTriggers Source #
pattern CardanoHardForkTriggers' ∷ c ~ StandardCrypto ⇒ CardanoHardForkTrigger (ShelleyBlock (TPraos c) (ShelleyEra c)) → CardanoHardForkTrigger (ShelleyBlock (TPraos c) (AllegraEra c)) → CardanoHardForkTrigger (ShelleyBlock (TPraos c) (MaryEra c)) → CardanoHardForkTrigger (ShelleyBlock (TPraos c) (AlonzoEra c)) → CardanoHardForkTrigger (ShelleyBlock (Praos c) (BabbageEra c)) → CardanoHardForkTrigger (ShelleyBlock (Praos c) (ConwayEra c)) → CardanoHardForkTriggers |