Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data ProtocolParameters = ProtocolParameters {
- ppScriptVersion ∷ !Word16
- ppSlotDuration ∷ !Natural
- ppMaxBlockSize ∷ !Natural
- ppMaxHeaderSize ∷ !Natural
- ppMaxTxSize ∷ !Natural
- ppMaxProposalSize ∷ !Natural
- ppMpcThd ∷ !LovelacePortion
- ppHeavyDelThd ∷ !LovelacePortion
- ppUpdateVoteThd ∷ !LovelacePortion
- ppUpdateProposalThd ∷ !LovelacePortion
- ppUpdateProposalTTL ∷ !SlotNumber
- ppSoftforkRule ∷ !SoftforkRule
- ppTxFeePolicy ∷ !TxFeePolicy
- ppUnlockStakeEpoch ∷ !EpochNumber
- upAdptThd ∷ Word8 → ProtocolParameters → Int
- isBootstrapEraPP ∷ ProtocolParameters → EpochNumber → Bool
Documentation
data ProtocolParameters Source #
Data which is associated with BlockVersion
ProtocolParameters | |
|
Instances
upAdptThd ∷ Word8 → ProtocolParameters → Int Source #
In Byron we do not have a upAdptThd
protocol parameter, so we have to
use the existing ones.
lovelacePortionToRational . srMinThd . ppSoftforkRule
will give us the
ratio (in the interval [0, 1]
) of the total stake that has to endorse a
protocol version to become adopted. In genesis configuration, this ratio
will evaluate to 0.6
, so if we have 7 genesis keys, upAdptThd = 4
.
isBootstrapEraPP ∷ ProtocolParameters → EpochNumber → Bool Source #
Version of isBootstrapEra
which takes ProtocolParameters
instead of
unlock stake epoch