Safe Haskell | Safe-Inferred |
---|---|
Language | GHC2021 |
Hydra.Tx.Abort
Contents
Synopsis
- data AbortTxError
- abortTx :: UTxO -> ScriptRegistry -> VerificationKey PaymentKey -> (TxIn, TxOut CtxUTxO) -> PlutusScript -> Map TxIn (TxOut CtxUTxO) -> Map TxIn (TxOut CtxUTxO) -> Either AbortTxError Tx
- newtype AbortObservation = AbortObservation {}
- observeAbortTx :: UTxO -> Tx -> Maybe AbortObservation
Creation
data AbortTxError Source #
Constructors
OverlappingInputs | |
CannotFindHeadOutputToAbort |
Instances
Show AbortTxError Source # | |
Defined in Hydra.Tx.Abort |
Arguments
:: UTxO | Committed UTxOs to reimburse. |
-> ScriptRegistry | Published Hydra scripts to reference. |
-> VerificationKey PaymentKey | Party who's authorizing this transaction |
-> (TxIn, TxOut CtxUTxO) | Everything needed to spend the Head state-machine output. |
-> PlutusScript | Script for monetary policy to burn tokens |
-> Map TxIn (TxOut CtxUTxO) | Data needed to spend the initial output sent to each party to the Head. Should contain the PT and is locked by initial script. |
-> Map TxIn (TxOut CtxUTxO) | Data needed to spend commit outputs. Should contain the PT and is locked by commit script. |
-> Either AbortTxError Tx |
Create transaction which aborts a head by spending the Head output and all other "initial" outputs.
Observation
newtype AbortObservation Source #
Constructors
AbortObservation | |
Instances
Generic AbortObservation Source # | |
Defined in Hydra.Tx.Abort Methods from :: AbortObservation -> Rep AbortObservation x Source # to :: Rep AbortObservation x -> AbortObservation Source # | |
Show AbortObservation Source # | |
Defined in Hydra.Tx.Abort | |
Eq AbortObservation Source # | |
Defined in Hydra.Tx.Abort Methods (==) :: AbortObservation -> AbortObservation -> Bool Source # (/=) :: AbortObservation -> AbortObservation -> Bool Source # | |
type Rep AbortObservation Source # | |
Defined in Hydra.Tx.Abort type Rep AbortObservation = D1 ('MetaData "AbortObservation" "Hydra.Tx.Abort" "hydra-tx-0.20.0-b01Sd51Fpn1r0Mfj7XdB1" 'True) (C1 ('MetaCons "AbortObservation" 'PrefixI 'True) (S1 ('MetaSel ('Just "headId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 HeadId))) |
Arguments
:: UTxO | A UTxO set to lookup tx inputs |
-> Tx | |
-> Maybe AbortObservation |
Identify an abort tx by looking up the input spending the Head output and decoding its redeemer.