| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Ledger.Value.CardanoAPI
Contents
Documentation
Instances
| Eq Value | |
| Show Value | |
| Semigroup Value | |
| Monoid Value | |
| Serialise Value | |
Defined in Ledger.Value.Orphans | |
| FromJSON Value | |
Defined in Cardano.Api.Value | |
| ToJSON Value | |
Defined in Cardano.Api.Value Methods toEncoding :: Value -> Encoding toJSONList :: [Value] -> Value0 toEncodingList :: [Value] -> Encoding | |
| JoinSemiLattice Value | |
Defined in Ledger.Value.CardanoAPI | |
| Pretty Value Source # | |
Defined in Ledger.Value.Orphans | |
Instances
Constructors
| AdaAssetId | |
| AssetId !PolicyId !AssetName |
Instances
| Eq AssetId | |
| Ord AssetId | |
Defined in Cardano.Api.Value | |
| Show AssetId | |
| Generic AssetId Source # | |
| Serialise AssetId | |
Defined in Ledger.Value.Orphans | |
| FromJSON AssetId | |
Defined in Ledger.Value.Orphans | |
| ToJSON AssetId | |
Defined in Ledger.Value.Orphans Methods toEncoding :: AssetId -> Encoding toJSONList :: [AssetId] -> Value toEncodingList :: [AssetId] -> Encoding | |
| Pretty AssetId Source # | |
Defined in Ledger.Value.Orphans | |
| type Rep AssetId Source # | |
Defined in Ledger.Value.Orphans type Rep AssetId = D1 ('MetaData "AssetId" "Cardano.Api.Value" "cardano-api-1.35.4-DlJBOMjUMEP4jWrRjidGIP" 'False) (C1 ('MetaCons "AdaAssetId" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "AssetId" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 PolicyId) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 AssetName))) | |
Instances
Instances
selectAsset :: Value -> AssetId -> Quantity #
valueToList :: Value -> [(AssetId, Quantity)] #
valueFromList :: [(AssetId, Quantity)] -> Value #
selectLovelace :: Value -> Lovelace #
negateValue :: Value -> Value #
lovelaceToValue :: Lovelace -> Value Source #
lovelaceValueOf :: Integer -> Value Source #
adaValueOf :: Rational -> Value Source #
isAdaOnlyValue :: Value -> Bool Source #
noAdaValue :: Value -> Value Source #
adaOnlyValue :: Value -> Value Source #
adaToCardanoValue :: Ada -> Value Source #
toCardanoValue :: Value -> Either ToCardanoError Value Source #
fromCardanoValue :: Value -> Value Source #
toCardanoAssetId :: AssetClass -> Either ToCardanoError AssetId Source #
fromCardanoAssetId :: AssetId -> AssetClass Source #