Skip to content

Commit

Permalink
Add LocalTxSubmissionStatus type
Browse files Browse the repository at this point in the history
  • Loading branch information
rvl committed Apr 8, 2021
1 parent f28b814 commit 7cb98fd
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions lib/core/src/Cardano/Wallet/Primitive/Types/Tx.hs
Expand Up @@ -28,6 +28,7 @@ module Cardano.Wallet.Primitive.Types.Tx
, UnsignedTx (..)
, TransactionInfo (..)
, Direction (..)
, LocalTxSubmissionStatus (..)
, TokenBundleSizeAssessor (..)
, TokenBundleSizeAssessment (..)

Expand Down Expand Up @@ -438,6 +439,17 @@ toTxHistory :: TransactionInfo -> (Tx, TxMeta)
toTxHistory info =
(fromTransactionInfo info, txInfoMeta info)

-- | Information about when a transaction was submitted to the local node.
-- This is used for scheduling resubmissions.
data LocalTxSubmissionStatus tx = LocalTxSubmissionStatus
{ txId :: !(Hash "Tx")
, submittedTx :: !tx
, firstSubmission :: !SlotNo
-- ^ Time of first successful submission to the local node.
, latestSubmission :: !SlotNo
-- ^ Time of most recent resubmission attempt.
} deriving (Generic, Show, Eq)

-- | A function capable of assessing the size of a token bundle relative to the
-- upper limit of what can be included in a single transaction output.
--
Expand Down

0 comments on commit 7cb98fd

Please sign in to comment.