Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
This module provides HasSpec
and HasSimpleRep
instances for
Basic types. A type is Basic
if it is used to define PParams.
See Test.Cardano.Ledger.Constrained.Conway.SimplePParams
We divide these HasSpec
and HasSimpleRep
instances into two files
because SimplePParams, needs these instances but not the 100's of other
ones defined in Test.Cardano.Ledger.Constrained.Conway.Instances.Ledger
And too many instances causes GHC 8.10.7 to blow up.
Synopsis
- cSNothing_ ∷ (HasSpec fn a, IsNormalType a) ⇒ Term fn (StrictMaybe a)
- cSJust_ ∷ (HasSpec fn a, IsNormalType a) ⇒ Term fn a → Term fn (StrictMaybe a)
- succV_ ∷ BaseUniverse fn ⇒ Term fn Version → Term fn Version
- makePrices ∷ Integer → Integer → Prices
- makeUnitInterval ∷ Integer → Integer → UnitInterval
- makeNonNegativeInterval ∷ Integer → Integer → NonNegativeInterval
- data SimplePParams era = SimplePParams {
- minFeeA ∷ Coin
- minFeeB ∷ Coin
- maxBBSize ∷ Word32
- maxTxSize ∷ Word32
- maxBHSize ∷ Word32
- keyDeposit ∷ Coin
- poolDeposit ∷ Coin
- eMax ∷ EpochInterval
- nOpt ∷ Natural
- a0 ∷ NonNegativeInterval
- rho ∷ UnitInterval
- tau ∷ UnitInterval
- decentral ∷ UnitInterval
- protocolVersion ∷ ProtVer
- minUTxOValue ∷ Coin
- minPoolCost ∷ Coin
- coinsPerUTxOWord ∷ Coin
- costModels ∷ CostModels
- prices ∷ Prices
- maxTxExUnits ∷ ExUnits
- maxBlockExUnits ∷ ExUnits
- maxValSize ∷ Natural
- collateralPercentage ∷ Natural
- maxCollateralInputs ∷ Natural
- coinsPerUTxOByte ∷ Coin
- poolVotingThresholds ∷ PoolVotingThresholds
- drepVotingThresholds ∷ DRepVotingThresholds
- committeeMinSize ∷ Natural
- committeeMaxTermLength ∷ EpochInterval
- govActionLifetime ∷ EpochInterval
- govActionDeposit ∷ Coin
- dRepDeposit ∷ Coin
- dRepActivity ∷ EpochInterval
- minFeeRefScriptCostPerByte ∷ NonNegativeInterval
- data SimplePPUpdate = SimplePPUpdate {
- uminFeeA ∷ StrictMaybe Coin
- uminFeeB ∷ StrictMaybe Coin
- umaxBBSize ∷ StrictMaybe Word32
- umaxTxSize ∷ StrictMaybe Word32
- umaxBHSize ∷ StrictMaybe Word32
- ukeyDeposit ∷ StrictMaybe Coin
- upoolDeposit ∷ StrictMaybe Coin
- ueMax ∷ StrictMaybe EpochInterval
- unOpt ∷ StrictMaybe Natural
- ua0 ∷ StrictMaybe NonNegativeInterval
- urho ∷ StrictMaybe UnitInterval
- utau ∷ StrictMaybe UnitInterval
- udecentral ∷ StrictMaybe UnitInterval
- uprotocolVersion ∷ StrictMaybe ProtVer
- uminUTxOValue ∷ StrictMaybe Coin
- uminPoolCost ∷ StrictMaybe Coin
- ucoinsPerUTxOWord ∷ StrictMaybe Coin
- ucostModels ∷ StrictMaybe CostModels
- uprices ∷ StrictMaybe Prices
- umaxTxExUnits ∷ StrictMaybe ExUnits
- umaxBlockExUnits ∷ StrictMaybe ExUnits
- umaxValSize ∷ StrictMaybe Natural
- ucollateralPercentage ∷ StrictMaybe Natural
- umaxCollateralInputs ∷ StrictMaybe Natural
- ucoinsPerUTxOByte ∷ StrictMaybe Coin
- upoolVotingThresholds ∷ StrictMaybe PoolVotingThresholds
- udrepVotingThresholds ∷ StrictMaybe DRepVotingThresholds
- ucommitteeMinSize ∷ StrictMaybe Natural
- ucommitteeMaxTermLength ∷ StrictMaybe EpochInterval
- ugovActionLifetime ∷ StrictMaybe EpochInterval
- ugovActionDeposit ∷ StrictMaybe Coin
- udRepDeposit ∷ StrictMaybe Coin
- udRepActivity ∷ StrictMaybe EpochInterval
- uminFeeRefScriptCostPerByte ∷ StrictMaybe NonNegativeInterval
- class (Reflect era, Eq (PParamsHKD Identity era), Show (PParamsHKD Identity era), Eq (PParamsHKD StrictMaybe era), Show (PParamsHKD StrictMaybe era), EraPParams era) ⇒ EraSpecPParams era where
- subsetToPP ∷ SimplePParams era → PParams era
- ppToSubset ∷ PParams era → SimplePParams era
- updateToPPU ∷ SimplePPUpdate → PParamsUpdate era
- ppuToUpdate ∷ PParamsUpdate era → SimplePPUpdate
Documentation
cSNothing_ ∷ (HasSpec fn a, IsNormalType a) ⇒ Term fn (StrictMaybe a) Source #
cSJust_ ∷ (HasSpec fn a, IsNormalType a) ⇒ Term fn a → Term fn (StrictMaybe a) Source #
data SimplePParams era Source #
Use this as the SimpleRep of (PParams era). It is polymorphic enough to encode PParams in EVERY Era. The EraPParams instances remove the fields that do not appear in that Era.
Instances
data SimplePPUpdate Source #
Use this as the SimpleRep of (PParamsUpdate era)
Instances
class (Reflect era, Eq (PParamsHKD Identity era), Show (PParamsHKD Identity era), Eq (PParamsHKD StrictMaybe era), Show (PParamsHKD StrictMaybe era), EraPParams era) ⇒ EraSpecPParams era where Source #
subsetToPP ∷ SimplePParams era → PParams era Source #
ppToSubset ∷ PParams era → SimplePParams era Source #
updateToPPU ∷ SimplePPUpdate → PParamsUpdate era Source #
ppuToUpdate ∷ PParamsUpdate era → SimplePPUpdate Source #
Instances
EraSpecPParams Allegra Source # | |
EraSpecPParams Alonzo Source # | |
EraSpecPParams Babbage Source # | |
EraSpecPParams Conway Source # | |
EraSpecPParams Mary Source # | |
EraSpecPParams Shelley Source # | |