Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- newtype TxId = TxId {}
- data TxIn = TxIn TxId Natural
- data TxOut = TxOut {}
- newtype UTxO = UTxO {}
- mapUTxOValues ∷ (Lovelace → Lovelace) → UTxO → UTxO
- addValue ∷ TxOut → Lovelace → TxOut
- fromTxOuts ∷ [TxOut] → UTxO
- data TxBody = TxBody {}
- txid ∷ TxBody → TxId
- txValue ∷ TxBody → Lovelace
- txins ∷ TxBody → [TxIn]
- txouts ∷ TxBody → UTxO
- balance ∷ UTxO → Lovelace
- pcMinFee ∷ PParams → Tx → Lovelace
- txsize ∷ Tx → Int
- data Wit = Wit VKey (Sig TxBody)
- data Tx = Tx {}
- makeWitness ∷ KeyPair → TxBody → Wit
- makeTxWits ∷ UTxO → TxBody → Tx
Documentation
A unique ID of a transaction, which is computable from the transaction.
Instances
Data TxId Source # | |
Defined in Byron.Spec.Ledger.UTxO gfoldl ∷ (∀ d b. Data d ⇒ c (d → b) → d → c b) → (∀ g. g → c g) → TxId → c TxId # gunfold ∷ (∀ b r. Data b ⇒ c (b → r) → c r) → (∀ r. r → c r) → Constr → c TxId # dataTypeOf ∷ TxId → DataType # dataCast1 ∷ Typeable t ⇒ (∀ d. Data d ⇒ c (t d)) → Maybe (c TxId) # dataCast2 ∷ Typeable t ⇒ (∀ d e. (Data d, Data e) ⇒ c (t d e)) → Maybe (c TxId) # gmapT ∷ (∀ b. Data b ⇒ b → b) → TxId → TxId # gmapQl ∷ (r → r' → r) → r → (∀ d. Data d ⇒ d → r') → TxId → r # gmapQr ∷ ∀ r r'. (r' → r → r) → r → (∀ d. Data d ⇒ d → r') → TxId → r # gmapQ ∷ (∀ d. Data d ⇒ d → u) → TxId → [u] # gmapQi ∷ Int → (∀ d. Data d ⇒ d → u) → TxId → u # gmapM ∷ Monad m ⇒ (∀ d. Data d ⇒ d → m d) → TxId → m TxId # gmapMp ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → TxId → m TxId # gmapMo ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → TxId → m TxId # | |
Generic TxId Source # | |
Show TxId Source # | |
HasTypeReps TxId Source # | |
Eq TxId Source # | |
Ord TxId Source # | |
Hashable TxId Source # | |
NoThunks TxId Source # | |
type Rep TxId Source # | |
The input of a UTxO.
- TODO - is it okay to use list indices instead of implementing the Ix Type?
Instances
Data TxIn Source # | |
Defined in Byron.Spec.Ledger.UTxO gfoldl ∷ (∀ d b. Data d ⇒ c (d → b) → d → c b) → (∀ g. g → c g) → TxIn → c TxIn # gunfold ∷ (∀ b r. Data b ⇒ c (b → r) → c r) → (∀ r. r → c r) → Constr → c TxIn # dataTypeOf ∷ TxIn → DataType # dataCast1 ∷ Typeable t ⇒ (∀ d. Data d ⇒ c (t d)) → Maybe (c TxIn) # dataCast2 ∷ Typeable t ⇒ (∀ d e. (Data d, Data e) ⇒ c (t d e)) → Maybe (c TxIn) # gmapT ∷ (∀ b. Data b ⇒ b → b) → TxIn → TxIn # gmapQl ∷ (r → r' → r) → r → (∀ d. Data d ⇒ d → r') → TxIn → r # gmapQr ∷ ∀ r r'. (r' → r → r) → r → (∀ d. Data d ⇒ d → r') → TxIn → r # gmapQ ∷ (∀ d. Data d ⇒ d → u) → TxIn → [u] # gmapQi ∷ Int → (∀ d. Data d ⇒ d → u) → TxIn → u # gmapM ∷ Monad m ⇒ (∀ d. Data d ⇒ d → m d) → TxIn → m TxIn # gmapMp ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → TxIn → m TxIn # gmapMo ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → TxIn → m TxIn # | |
Generic TxIn Source # | |
Show TxIn Source # | |
HasTypeReps TxIn Source # | |
Eq TxIn Source # | |
Ord TxIn Source # | |
Hashable TxIn Source # | |
NoThunks TxIn Source # | |
type Rep TxIn Source # | |
Defined in Byron.Spec.Ledger.UTxO type Rep TxIn = D1 ('MetaData "TxIn" "Byron.Spec.Ledger.UTxO" "byron-spec-ledger-1.0.1.0-inplace" 'False) (C1 ('MetaCons "TxIn" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 TxId) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Natural))) |
The output of a UTxO.
Instances
Data TxOut Source # | |
Defined in Byron.Spec.Ledger.UTxO gfoldl ∷ (∀ d b. Data d ⇒ c (d → b) → d → c b) → (∀ g. g → c g) → TxOut → c TxOut # gunfold ∷ (∀ b r. Data b ⇒ c (b → r) → c r) → (∀ r. r → c r) → Constr → c TxOut # dataTypeOf ∷ TxOut → DataType # dataCast1 ∷ Typeable t ⇒ (∀ d. Data d ⇒ c (t d)) → Maybe (c TxOut) # dataCast2 ∷ Typeable t ⇒ (∀ d e. (Data d, Data e) ⇒ c (t d e)) → Maybe (c TxOut) # gmapT ∷ (∀ b. Data b ⇒ b → b) → TxOut → TxOut # gmapQl ∷ (r → r' → r) → r → (∀ d. Data d ⇒ d → r') → TxOut → r # gmapQr ∷ ∀ r r'. (r' → r → r) → r → (∀ d. Data d ⇒ d → r') → TxOut → r # gmapQ ∷ (∀ d. Data d ⇒ d → u) → TxOut → [u] # gmapQi ∷ Int → (∀ d. Data d ⇒ d → u) → TxOut → u # gmapM ∷ Monad m ⇒ (∀ d. Data d ⇒ d → m d) → TxOut → m TxOut # gmapMp ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → TxOut → m TxOut # gmapMo ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → TxOut → m TxOut # | |
Generic TxOut Source # | |
Show TxOut Source # | |
HasTypeReps TxOut Source # | |
Eq TxOut Source # | |
Ord TxOut Source # | |
Hashable TxOut Source # | |
NoThunks TxOut Source # | |
type Rep TxOut Source # | |
Defined in Byron.Spec.Ledger.UTxO type Rep TxOut = D1 ('MetaData "TxOut" "Byron.Spec.Ledger.UTxO" "byron-spec-ledger-1.0.1.0-inplace" 'False) (C1 ('MetaCons "TxOut" 'PrefixI 'True) (S1 ('MetaSel ('Just "addr") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Addr) :*: S1 ('MetaSel ('Just "value") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Lovelace))) |
The unspent transaction outputs.
Instances
mapUTxOValues ∷ (Lovelace → Lovelace) → UTxO → UTxO Source #
Apply function uniformly across all outputs
fromTxOuts ∷ [TxOut] → UTxO Source #
Construct a UTxO from initial TxOuts
A raw transaction
Instances
Data TxBody Source # | |
Defined in Byron.Spec.Ledger.UTxO gfoldl ∷ (∀ d b. Data d ⇒ c (d → b) → d → c b) → (∀ g. g → c g) → TxBody → c TxBody # gunfold ∷ (∀ b r. Data b ⇒ c (b → r) → c r) → (∀ r. r → c r) → Constr → c TxBody # dataTypeOf ∷ TxBody → DataType # dataCast1 ∷ Typeable t ⇒ (∀ d. Data d ⇒ c (t d)) → Maybe (c TxBody) # dataCast2 ∷ Typeable t ⇒ (∀ d e. (Data d, Data e) ⇒ c (t d e)) → Maybe (c TxBody) # gmapT ∷ (∀ b. Data b ⇒ b → b) → TxBody → TxBody # gmapQl ∷ (r → r' → r) → r → (∀ d. Data d ⇒ d → r') → TxBody → r # gmapQr ∷ ∀ r r'. (r' → r → r) → r → (∀ d. Data d ⇒ d → r') → TxBody → r # gmapQ ∷ (∀ d. Data d ⇒ d → u) → TxBody → [u] # gmapQi ∷ Int → (∀ d. Data d ⇒ d → u) → TxBody → u # gmapM ∷ Monad m ⇒ (∀ d. Data d ⇒ d → m d) → TxBody → m TxBody # gmapMp ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → TxBody → m TxBody # gmapMo ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → TxBody → m TxBody # | |
Generic TxBody Source # | |
Show TxBody Source # | |
HasHash TxBody Source # | |
HasTypeReps TxBody Source # | |
Eq TxBody Source # | |
Ord TxBody Source # | |
Hashable TxBody Source # | |
NoThunks TxBody Source # | |
type Rep TxBody Source # | |
Defined in Byron.Spec.Ledger.UTxO type Rep TxBody = D1 ('MetaData "TxBody" "Byron.Spec.Ledger.UTxO" "byron-spec-ledger-1.0.1.0-inplace" 'False) (C1 ('MetaCons "TxBody" 'PrefixI 'True) (S1 ('MetaSel ('Just "inputs") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 [TxIn]) :*: S1 ('MetaSel ('Just "outputs") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 [TxOut]))) |
Proof/Witness that a transaction is authorized by the given key holder.
Instances
Data Wit Source # | |
Defined in Byron.Spec.Ledger.UTxO gfoldl ∷ (∀ d b. Data d ⇒ c (d → b) → d → c b) → (∀ g. g → c g) → Wit → c Wit # gunfold ∷ (∀ b r. Data b ⇒ c (b → r) → c r) → (∀ r. r → c r) → Constr → c Wit # dataTypeOf ∷ Wit → DataType # dataCast1 ∷ Typeable t ⇒ (∀ d. Data d ⇒ c (t d)) → Maybe (c Wit) # dataCast2 ∷ Typeable t ⇒ (∀ d e. (Data d, Data e) ⇒ c (t d e)) → Maybe (c Wit) # gmapT ∷ (∀ b. Data b ⇒ b → b) → Wit → Wit # gmapQl ∷ (r → r' → r) → r → (∀ d. Data d ⇒ d → r') → Wit → r # gmapQr ∷ ∀ r r'. (r' → r → r) → r → (∀ d. Data d ⇒ d → r') → Wit → r # gmapQ ∷ (∀ d. Data d ⇒ d → u) → Wit → [u] # gmapQi ∷ Int → (∀ d. Data d ⇒ d → u) → Wit → u # gmapM ∷ Monad m ⇒ (∀ d. Data d ⇒ d → m d) → Wit → m Wit # gmapMp ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → Wit → m Wit # gmapMo ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → Wit → m Wit # | |
Generic Wit Source # | |
Show Wit Source # | |
HasTypeReps Wit Source # | |
Eq Wit Source # | |
Ord Wit Source # | |
Hashable Wit Source # | |
NoThunks Wit Source # | |
type Rep Wit Source # | |
Defined in Byron.Spec.Ledger.UTxO type Rep Wit = D1 ('MetaData "Wit" "Byron.Spec.Ledger.UTxO" "byron-spec-ledger-1.0.1.0-inplace" 'False) (C1 ('MetaCons "Wit" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 VKey) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Sig TxBody)))) |
A fully formed transaction.
Instances
Data Tx Source # | |
Defined in Byron.Spec.Ledger.UTxO gfoldl ∷ (∀ d b. Data d ⇒ c (d → b) → d → c b) → (∀ g. g → c g) → Tx → c Tx # gunfold ∷ (∀ b r. Data b ⇒ c (b → r) → c r) → (∀ r. r → c r) → Constr → c Tx # dataTypeOf ∷ Tx → DataType # dataCast1 ∷ Typeable t ⇒ (∀ d. Data d ⇒ c (t d)) → Maybe (c Tx) # dataCast2 ∷ Typeable t ⇒ (∀ d e. (Data d, Data e) ⇒ c (t d e)) → Maybe (c Tx) # gmapT ∷ (∀ b. Data b ⇒ b → b) → Tx → Tx # gmapQl ∷ (r → r' → r) → r → (∀ d. Data d ⇒ d → r') → Tx → r # gmapQr ∷ ∀ r r'. (r' → r → r) → r → (∀ d. Data d ⇒ d → r') → Tx → r # gmapQ ∷ (∀ d. Data d ⇒ d → u) → Tx → [u] # gmapQi ∷ Int → (∀ d. Data d ⇒ d → u) → Tx → u # gmapM ∷ Monad m ⇒ (∀ d. Data d ⇒ d → m d) → Tx → m Tx # gmapMp ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → Tx → m Tx # gmapMo ∷ MonadPlus m ⇒ (∀ d. Data d ⇒ d → m d) → Tx → m Tx # | |
Generic Tx Source # | |
Show Tx Source # | |
HasTypeReps Tx Source # | |
Eq Tx Source # | |
Hashable Tx Source # | |
NoThunks Tx Source # | |
HasHash [Tx] Source # | |
type Rep Tx Source # | |
Defined in Byron.Spec.Ledger.UTxO type Rep Tx = D1 ('MetaData "Tx" "Byron.Spec.Ledger.UTxO" "byron-spec-ledger-1.0.1.0-inplace" 'False) (C1 ('MetaCons "Tx" 'PrefixI 'True) (S1 ('MetaSel ('Just "body") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 TxBody) :*: S1 ('MetaSel ('Just "witnesses") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 [Wit]))) |