Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Cooked.Skeleton.Proposal
Description
This module exposes the notion of proposal within a
TxSkel
Synopsis
- data TxParameterChange where
- FeePerByte :: Integer -> TxParameterChange
- FeeFixed :: Integer -> TxParameterChange
- MaxBlockBodySize :: Integer -> TxParameterChange
- MaxTxSize :: Integer -> TxParameterChange
- MaxBlockHeaderSize :: Integer -> TxParameterChange
- KeyDeposit :: Integer -> TxParameterChange
- PoolDeposit :: Integer -> TxParameterChange
- PoolRetirementMaxEpoch :: Integer -> TxParameterChange
- PoolNumber :: Integer -> TxParameterChange
- PoolInfluence :: Rational -> TxParameterChange
- MonetaryExpansion :: Rational -> TxParameterChange
- TreasuryCut :: Rational -> TxParameterChange
- MinPoolCost :: Integer -> TxParameterChange
- CoinsPerUTxOByte :: Integer -> TxParameterChange
- CostModels :: {..} -> TxParameterChange
- Prices :: {..} -> TxParameterChange
- MaxTxExUnits :: {..} -> TxParameterChange
- MaxBlockExUnits :: {..} -> TxParameterChange
- MaxValSize :: Integer -> TxParameterChange
- CollateralPercentage :: Integer -> TxParameterChange
- MaxCollateralInputs :: Integer -> TxParameterChange
- PoolVotingThresholds :: {..} -> TxParameterChange
- DRepVotingThresholds :: {..} -> TxParameterChange
- CommitteeMinSize :: Integer -> TxParameterChange
- CommitteeMaxTermLength :: Integer -> TxParameterChange
- GovActionLifetime :: Integer -> TxParameterChange
- GovActionDeposit :: Integer -> TxParameterChange
- DRepRegistrationDeposit :: Integer -> TxParameterChange
- DRepActivity :: Integer -> TxParameterChange
- MinFeeRefScriptCostPerByte :: Rational -> TxParameterChange
- data TxGovAction where
- TxGovActionParameterChange :: [TxParameterChange] -> TxGovAction
- TxGovActionHardForkInitiation :: ProtocolVersion -> TxGovAction
- TxGovActionTreasuryWithdrawals :: Map Credential Lovelace -> TxGovAction
- TxGovActionNoConfidence :: TxGovAction
- TxGovActionUpdateCommittee :: [ColdCommitteeCredential] -> Map ColdCommitteeCredential Integer -> Rational -> TxGovAction
- TxGovActionNewConstitution :: Constitution -> TxGovAction
- data TxSkelProposal where
- TxSkelProposal :: {..} -> TxSkelProposal
- txSkelProposalAddressL :: Lens' TxSkelProposal Address
- txSkelProposalActionL :: Lens' TxSkelProposal TxGovAction
- txSkelProposalWitnessL :: Lens' TxSkelProposal (Maybe (Versioned Script, TxSkelRedeemer))
- txSkelProposalAnchorL :: Lens' TxSkelProposal (Maybe String)
- txSkelProposalAutoConstitutionL :: Lens' TxSkelProposal Bool
- simpleTxSkelProposal :: ToAddress a => a -> TxGovAction -> TxSkelProposal
- withWitness :: ToVersioned Script a => TxSkelProposal -> (a, TxSkelRedeemer) -> TxSkelProposal
- withAnchor :: TxSkelProposal -> String -> TxSkelProposal
- withConstitution :: ToVersioned Script a => TxSkelProposal -> Maybe a -> TxSkelProposal
- updateConstitution :: ToVersioned Script a => TxSkelProposal -> Maybe a -> TxSkelProposal
Documentation
data TxParameterChange where Source #
These are all the protocol parameters. They are taken from https://github.com/IntersectMBO/cardano-ledger/blob/c4fbc05999866fea7c0cb1b211fd5288f286b95d/eras/conway/impl/cddl-files/conway.cddl#L381-L412 and will most likely change in future eras.
Constructors
Instances
Show TxParameterChange Source # | |
Defined in Cooked.Skeleton.Proposal Methods showsPrec :: Int -> TxParameterChange -> ShowS # show :: TxParameterChange -> String # showList :: [TxParameterChange] -> ShowS # | |
PrettyCooked TxParameterChange Source # | |
Defined in Cooked.Pretty.Skeleton Methods prettyCookedOpt :: PrettyCookedOpts -> TxParameterChange -> DocCooked Source # | |
Eq TxParameterChange Source # | |
Defined in Cooked.Skeleton.Proposal Methods (==) :: TxParameterChange -> TxParameterChange -> Bool # (/=) :: TxParameterChange -> TxParameterChange -> Bool # |
data TxGovAction where Source #
This lists the various possible governance actions
Constructors
Instances
Show TxGovAction Source # | |
Defined in Cooked.Skeleton.Proposal Methods showsPrec :: Int -> TxGovAction -> ShowS # show :: TxGovAction -> String # showList :: [TxGovAction] -> ShowS # | |
PrettyCooked TxGovAction Source # | |
Defined in Cooked.Pretty.Skeleton Methods prettyCookedOpt :: PrettyCookedOpts -> TxGovAction -> DocCooked Source # prettyCooked :: TxGovAction -> DocCooked Source # | |
Eq TxGovAction Source # | |
Defined in Cooked.Skeleton.Proposal |
data TxSkelProposal where Source #
This bundles a governance action into an actual proposal
Constructors
TxSkelProposal | |
Fields
|
Instances
Show TxSkelProposal Source # | |
Defined in Cooked.Skeleton.Proposal Methods showsPrec :: Int -> TxSkelProposal -> ShowS # show :: TxSkelProposal -> String # showList :: [TxSkelProposal] -> ShowS # | |
PrettyCookedList TxSkelProposal Source # | |
Defined in Cooked.Pretty.Skeleton Methods prettyCookedOptList :: PrettyCookedOpts -> TxSkelProposal -> [DocCooked] Source # prettyCookedOptListMaybe :: PrettyCookedOpts -> TxSkelProposal -> [Maybe DocCooked] Source # prettyCookedList :: TxSkelProposal -> [DocCooked] Source # | |
Eq TxSkelProposal Source # | |
Defined in Cooked.Skeleton.Proposal Methods (==) :: TxSkelProposal -> TxSkelProposal -> Bool # (/=) :: TxSkelProposal -> TxSkelProposal -> Bool # |
txSkelProposalAddressL :: Lens' TxSkelProposal Address Source #
A lens to get or set the address of a TxSkelProposal
txSkelProposalActionL :: Lens' TxSkelProposal TxGovAction Source #
A lens to get or set the governance action of a TxSkelProposal
txSkelProposalWitnessL :: Lens' TxSkelProposal (Maybe (Versioned Script, TxSkelRedeemer)) Source #
A lens to get or set the witness of a TxSkelProposal
txSkelProposalAnchorL :: Lens' TxSkelProposal (Maybe String) Source #
A lens to get or set the anchor of a TxSkelProposal
txSkelProposalAutoConstitutionL :: Lens' TxSkelProposal Bool Source #
A lens to get or set the anchor of a TxSkelProposal
simpleTxSkelProposal :: ToAddress a => a -> TxGovAction -> TxSkelProposal Source #
Builds a TxSkelProposal
from an address and a TxGovAction
withWitness :: ToVersioned Script a => TxSkelProposal -> (a, TxSkelRedeemer) -> TxSkelProposal Source #
Assigns a witness to a TxSkelProposal
. Also turns off the auto
constitution flag, so that this witness is not overridden.
withAnchor :: TxSkelProposal -> String -> TxSkelProposal Source #
Assigns an anchor to a TxSkelProposal
withConstitution :: ToVersioned Script a => TxSkelProposal -> Maybe a -> TxSkelProposal Source #
Assigns the constitution script with an empty redeemer
updateConstitution :: ToVersioned Script a => TxSkelProposal -> Maybe a -> TxSkelProposal Source #
Updates the constitution if txSkelProposalAutoConstitution
is True