hydra-cardano-api-0.20.0: A Haskell API for Cardano, tailored to the Hydra project.
Safe HaskellSafe-Inferred
LanguageGHC2021

Hydra.Cardano.Api.Value

Synopsis

Extras

minUTxOValue :: PParams LedgerEra -> TxOut CtxTx Era -> Value Source #

Calculate minimum ada as Value for a TxOut.

valueSize :: Value -> Int Source #

Count number of assets in a Value.

txMintAssets :: Tx era -> [(AssetId, Quantity)] Source #

Access minted assets of a transaction, as an ordered association list.

Type Conversions

fromLedgerValue :: MaryValue StandardCrypto -> Value Source #

Convert a cardano-ledger Value into a cardano-api Value.

fromLedgerMultiAsset :: MultiAsset StandardCrypto -> Value Source #

Convert a cardano-ledger MultiAsset into a cardano-api Value. The cardano-api currently does not have an asset-only type. So this conversion will construct a Value with no AdaAssetId entry in it.

toLedgerValue :: Value -> MaryValue StandardCrypto Source #

Convert a cardano-api Value into a cardano-ledger Value.

fromPlutusValue :: Value -> Maybe Value Source #

Convert a plutus Value into a cardano-api Value.

toPlutusValue :: Value -> Value Source #

Convert a cardano-api Value into a plutus Value