hydra-tx-0.20.0: Hydra transaction library
Safe HaskellSafe-Inferred
LanguageGHC2021

Hydra.Tx.Close

Synopsis

Construction

type PointInTime = (SlotNo, UTCTime) Source #

closeTx Source #

Arguments

:: ScriptRegistry

Published Hydra scripts to reference.

-> VerificationKey PaymentKey

Party who's authorizing this transaction

-> HeadId

Head identifier

-> SnapshotVersion

Last known version of the open head.

-> ConfirmedSnapshot Tx

Snapshot with instructions how to close the head.

-> SlotNo

Lower validity slot number, usually a current or quite recent slot number.

-> PointInTime

Upper validity slot and UTC time to compute the contestation deadline time.

-> OpenThreadOutput

Everything needed to spend the Head state-machine output.

-> IncrementalAction 
-> Tx 

Create a transaction closing a head with either the initial snapshot or with a multi-signed confirmed snapshot.

Observation

data ClosedThreadOutput Source #

Constructors

ClosedThreadOutput 

Fields

Instances

Instances details
Generic ClosedThreadOutput Source # 
Instance details

Defined in Hydra.Tx.Close

Associated Types

type Rep ClosedThreadOutput :: Type -> Type Source #

Show ClosedThreadOutput Source # 
Instance details

Defined in Hydra.Tx.Close

Eq ClosedThreadOutput Source # 
Instance details

Defined in Hydra.Tx.Close

type Rep ClosedThreadOutput Source # 
Instance details

Defined in Hydra.Tx.Close

type Rep ClosedThreadOutput = D1 ('MetaData "ClosedThreadOutput" "Hydra.Tx.Close" "hydra-tx-0.20.0-b01Sd51Fpn1r0Mfj7XdB1" 'False) (C1 ('MetaCons "ClosedThreadOutput" 'PrefixI 'True) ((S1 ('MetaSel ('Just "closedThreadUTxO") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (TxIn, TxOut CtxUTxO)) :*: S1 ('MetaSel ('Just "closedParties") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Party])) :*: (S1 ('MetaSel ('Just "closedContestationDeadline") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 POSIXTime) :*: S1 ('MetaSel ('Just "closedContesters") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [PubKeyHash]))))

observeCloseTx Source #

Arguments

:: UTxO

A UTxO set to lookup tx inputs

-> Tx 
-> Maybe CloseObservation 

Identify a close tx by lookup up the input spending the Head output and decoding its redeemer.