MCPcopy Create free account
hub / github.com/ElementsProject/elements / CTxMemPoolModifiedEntry

Class CTxMemPoolModifiedEntry

src/node/miner.h:39–62  ·  view source on GitHub ↗

Container for tracking updates to ancestor feerate as we include (parent) transactions in a block

Source from the content-addressed store, hash-verified

37// Container for tracking updates to ancestor feerate as we include (parent)
38// transactions in a block
39struct CTxMemPoolModifiedEntry {
40 explicit CTxMemPoolModifiedEntry(CTxMemPool::txiter entry)
41 {
42 iter = entry;
43 nSizeWithAncestors = entry->GetSizeWithAncestors();
44 discountSizeWithAncestors = entry->GetDiscountSizeWithAncestors();
45 nModFeesWithAncestors = entry->GetModFeesWithAncestors();
46 nSigOpCostWithAncestors = entry->GetSigOpCostWithAncestors();
47 }
48
49 CAmount GetModifiedFee() const { return iter->GetModifiedFee(); }
50 uint64_t GetSizeWithAncestors() const { return nSizeWithAncestors; }
51 uint64_t GetDiscountSizeWithAncestors() const { return discountSizeWithAncestors; }
52 CAmount GetModFeesWithAncestors() const { return nModFeesWithAncestors; }
53 size_t GetTxSize() const { return iter->GetTxSize(); }
54 size_t GetDiscountTxSize() const { return iter->GetDiscountTxSize(); }
55 const CTransaction& GetTx() const { return iter->GetTx(); }
56
57 CTxMemPool::txiter iter;
58 uint64_t nSizeWithAncestors;
59 uint64_t discountSizeWithAncestors;
60 CAmount nModFeesWithAncestors;
61 int64_t nSigOpCostWithAncestors;
62};
63
64/** Comparator for CTxMemPool::txiter objects.
65 * It simply compares the internal memory address of the CTxMemPoolEntry object

Callers 1

addPackageTxsMethod · 0.85

Calls 1

GetTxMethod · 0.80

Tested by

no test coverage detected