| Safe Haskell | Safe-Inferred |
|---|---|
| Language | GHC2021 |
Hydra.Model.Payment
Contents
Description
A simplistic type of transactions useful for modelling purpose.
a Payment is a simple transaction type that moves some amount of ADAs between
to CardanoSigningKey.
Synopsis
- newtype CardanoSigningKey = CardanoSigningKey {
- signingKey :: Secret (SigningKey PaymentKey)
- data Payment = Payment {
- from :: CardanoSigningKey
- to :: CardanoSigningKey
- value :: Value
- applyTx :: UTxOType Payment -> Payment -> UTxOType Payment
- genAdaValue :: Gen Value
Documentation
newtype CardanoSigningKey Source #
New type wrapper to add Ord and Eq instances to signing keys. The
inner 'SigningKey PaymentKey' is wrapped in Secret: the signingKey
field never exposes the raw key, mirroring the way Hydra signing keys
are handled. The accompanying ToJSON FromJSON ToCBOR /
FromCBOR bans are inherited from Secret.
Constructors
| CardanoSigningKey | |
Fields
| |
Instances
A single Ada-payment only transaction in our model.
Constructors
| Payment | |
Fields
| |
Instances
genAdaValue :: Gen Value Source #
Orphans
Orphan instances
| Arbitrary Value Source # | |
| FromCBOR Value Source # | |
| ToCBOR Value Source # | |
Methods toCBOR :: Value -> Encoding encodedSizeExpr :: (forall t. ToCBOR t => Proxy t -> Size) -> Proxy Value -> Size encodedListSizeExpr :: (forall t. ToCBOR t => Proxy t -> Size) -> Proxy [Value] -> Size | |
| Ord Value Source # | Orphan |