20 #include <ripple/app/ledger/Ledger.h>
21 #include <ripple/app/ledger/LocalTxs.h>
22 #include <ripple/app/main/Application.h>
23 #include <ripple/protocol/Indexes.h>
64 ,
m_id(txn->getTransactionID())
66 ,
m_seq(txn->getSequence())
125 m_txns.emplace_back(index, txn);
138 for (
auto const& it :
m_txns)
139 tset.insert(it.getTX());
153 m_txns.remove_if([&view](
auto const& txn) {
154 if (txn.isExpired(view.
info().
seq))
163 return sle->getFieldU32(
sfSequence) > txn.getSeq();
183 return std::make_unique<LocalTxsImp>();
virtual LedgerInfo const & info() const =0
Returns information about the ledger.
AccountID const & getAccount() const
std::uint32_t getSeq() const
std::list< LocalTx > m_txns
bool isExpired(LedgerIndex i) const
const SF_U32 sfSequence(access, STI_UINT32, 4, "Sequence")
const SF_Account sfAccount(access, STI_ACCOUNT, 1, "Account")
void sweep(ReadView const &view) override
void push_back(LedgerIndex index, std::shared_ptr< STTx const > const &txn) override
LocalTx(LedgerIndex index, std::shared_ptr< STTx const > const &txn)
virtual bool txExists(key_type const &key) const =0
Returns true if a tx exists in the tx map.
Holds transactions which were deferred to the next pass of consensus.
const SF_U32 sfLastLedgerSequence(access, STI_UINT32, 27, "LastLedgerSequence")
Keylet account(AccountID const &id) noexcept
AccountID root.
std::shared_ptr< STTx const > const & getTX() const
uint256 const & getID() const
virtual std::shared_ptr< SLE const > read(Keylet const &k) const =0
Return the state item associated with a key.
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
std::size_t size() override
std::unique_ptr< LocalTxs > make_LocalTxs()
CanonicalTXSet getTxSet() override
std::shared_ptr< STTx const > m_txn
static const int holdLedgers