Safe Haskell | Safe-Inferred |
---|---|
Language | GHC2021 |
Synopsis
- adjustUTxO :: Tx -> UTxO -> UTxO
- fromChainSlot :: ChainSlot -> SlotNo
- cardanoLedger :: Globals -> LedgerEnv LedgerEra -> Ledger Tx
- newLedgerEnv :: PParams LedgerEra -> LedgerEnv LedgerEra
- mkTransferTx :: MonadFail m => NetworkId -> UTxO -> SigningKey PaymentKey -> VerificationKey PaymentKey -> m Tx
- mkSimpleTx :: (TxIn, TxOut CtxUTxO) -> (AddressInEra, Value) -> SigningKey PaymentKey -> Either TxBodyError Tx
- mkRangedTx :: (TxIn, TxOut CtxUTxO) -> (AddressInEra, Value) -> SigningKey PaymentKey -> (Maybe TxValidityLowerBound, Maybe TxValidityUpperBound) -> Either TxBodyError Tx
- genSequenceOfSimplePaymentTransactions :: Gen (UTxO, [Tx])
- genFixedSizeSequenceOfSimplePaymentTransactions :: Int -> Gen (UTxO, [Tx])
- data ShelleyGenesis c = ShelleyGenesis {
- sgSystemStart :: !UTCTime
- sgNetworkMagic :: !Word32
- sgNetworkId :: !Network
- sgActiveSlotsCoeff :: !PositiveUnitInterval
- sgSecurityParam :: !Word64
- sgEpochLength :: !EpochSize
- sgSlotsPerKESPeriod :: !Word64
- sgMaxKESEvolutions :: !Word64
- sgSlotLength :: !NominalDiffTimeMicro
- sgUpdateQuorum :: !Word64
- sgMaxLovelaceSupply :: !Word64
- sgProtocolParams :: !(PParams (ShelleyEra c))
- sgGenDelegs :: !(Map (KeyHash 'Genesis c) (GenDelegPair c))
- sgInitialFunds :: ListMap (Addr c) Coin
- sgStaking :: ShelleyGenesisStaking c
- data Globals
- data LedgerEnv era
- type Tx = Tx Era
Documentation
adjustUTxO :: Tx -> UTxO -> UTxO Source #
fromChainSlot :: ChainSlot -> SlotNo Source #
Simple conversion from a generic slot to a specific local one.
cardanoLedger :: Globals -> LedgerEnv LedgerEra -> Ledger Tx Source #
Use the cardano-ledger as an in-hydra Ledger
.
newLedgerEnv :: PParams LedgerEra -> LedgerEnv LedgerEra Source #
Create a new ledger env from given protocol parameters.
mkTransferTx :: MonadFail m => NetworkId -> UTxO -> SigningKey PaymentKey -> VerificationKey PaymentKey -> m Tx Source #
Build a zero-fee transaction which spends the first output owned by given signing key and transfers it in full to given verification key.
:: (TxIn, TxOut CtxUTxO) | |
-> (AddressInEra, Value) | Recipient address and amount. |
-> SigningKey PaymentKey | Sender's signing key. |
-> Either TxBodyError Tx |
Build a zero-fee payment transaction.
:: (TxIn, TxOut CtxUTxO) | |
-> (AddressInEra, Value) | Recipient address and amount. |
-> SigningKey PaymentKey | Sender's signing key. |
-> (Maybe TxValidityLowerBound, Maybe TxValidityUpperBound) | |
-> Either TxBodyError Tx |
Create a zero-fee, payment cardano transaction with validity range.
genSequenceOfSimplePaymentTransactions :: Gen (UTxO, [Tx]) Source #
Generates a sequence of simple "transfer" transactions for a single key.
genFixedSizeSequenceOfSimplePaymentTransactions :: Int -> Gen (UTxO, [Tx]) Source #
data ShelleyGenesis c #
ShelleyGenesis | |
|
Instances
Instances
Instances
Generic (LedgerEnv era) | |
Show (PParams era) => Show (LedgerEnv era) | |
NFData (PParams era) => NFData (LedgerEnv era) | |
Defined in Cardano.Ledger.Shelley.Rules.Ledger | |
Eq (PParams era) => Eq (LedgerEnv era) | |
type Rep (LedgerEnv era) | |
Defined in Cardano.Ledger.Shelley.Rules.Ledger type Rep (LedgerEnv era) = D1 ('MetaData "LedgerEnv" "Cardano.Ledger.Shelley.Rules.Ledger" "cardano-ledger-shelley-1.13.1.0-o3mJ5dyFPF19pt5MIUFUd" 'False) (C1 ('MetaCons "LedgerEnv" 'PrefixI 'True) ((S1 ('MetaSel ('Just "ledgerSlotNo") 'NoSourceUnpackedness 'SourceStrict 'DecidedUnpack) (Rec0 SlotNo) :*: S1 ('MetaSel ('Just "ledgerIx") 'NoSourceUnpackedness 'SourceStrict 'DecidedUnpack) (Rec0 TxIx)) :*: (S1 ('MetaSel ('Just "ledgerPp") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (PParams era)) :*: S1 ('MetaSel ('Just "ledgerAccount") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 AccountState)))) |