mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-02-10 10:52:31 -05:00
Remove unused submitToMemoryPool and relayTransactions Chain interfaces
This commit is contained in:
parent
8753f5652b
commit
b8eecf8e79
2 changed files with 0 additions and 22 deletions
|
@ -151,12 +151,6 @@ class LockImpl : public Chain::Lock, public UniqueLock<CCriticalSection>
|
||||||
LockAssertion lock(::cs_main);
|
LockAssertion lock(::cs_main);
|
||||||
return CheckFinalTx(tx);
|
return CheckFinalTx(tx);
|
||||||
}
|
}
|
||||||
bool submitToMemoryPool(const CTransactionRef& tx, CAmount absurd_fee, CValidationState& state) override
|
|
||||||
{
|
|
||||||
LockAssertion lock(::cs_main);
|
|
||||||
return AcceptToMemoryPool(::mempool, state, tx, nullptr /* missing inputs */, nullptr /* txn replaced */,
|
|
||||||
false /* bypass limits */, absurd_fee);
|
|
||||||
}
|
|
||||||
|
|
||||||
using UniqueLock::UniqueLock;
|
using UniqueLock::UniqueLock;
|
||||||
};
|
};
|
||||||
|
@ -292,10 +286,6 @@ public:
|
||||||
auto it = ::mempool.GetIter(txid);
|
auto it = ::mempool.GetIter(txid);
|
||||||
return it && (*it)->GetCountWithDescendants() > 1;
|
return it && (*it)->GetCountWithDescendants() > 1;
|
||||||
}
|
}
|
||||||
void relayTransaction(const uint256& txid) override
|
|
||||||
{
|
|
||||||
RelayTransaction(txid, *g_connman);
|
|
||||||
}
|
|
||||||
bool broadcastTransaction(const CTransactionRef& tx, std::string& err_string, const CAmount& max_tx_fee, bool relay) override
|
bool broadcastTransaction(const CTransactionRef& tx, std::string& err_string, const CAmount& max_tx_fee, bool relay) override
|
||||||
{
|
{
|
||||||
const TransactionError err = BroadcastTransaction(tx, err_string, max_tx_fee, relay, /*wait_callback*/ false);
|
const TransactionError err = BroadcastTransaction(tx, err_string, max_tx_fee, relay, /*wait_callback*/ false);
|
||||||
|
|
|
@ -43,10 +43,6 @@ class Wallet;
|
||||||
//! asynchronously
|
//! asynchronously
|
||||||
//! (https://github.com/bitcoin/bitcoin/pull/10973#issuecomment-380101269).
|
//! (https://github.com/bitcoin/bitcoin/pull/10973#issuecomment-380101269).
|
||||||
//!
|
//!
|
||||||
//! * The relayTransactions() and submitToMemoryPool() methods could be replaced
|
|
||||||
//! with a higher-level broadcastTransaction method
|
|
||||||
//! (https://github.com/bitcoin/bitcoin/pull/14978#issuecomment-459373984).
|
|
||||||
//!
|
|
||||||
//! * The initMessages() and loadWallet() methods which the wallet uses to send
|
//! * The initMessages() and loadWallet() methods which the wallet uses to send
|
||||||
//! notifications to the GUI should go away when GUI and wallet can directly
|
//! notifications to the GUI should go away when GUI and wallet can directly
|
||||||
//! communicate with each other without going through the node
|
//! communicate with each other without going through the node
|
||||||
|
@ -127,11 +123,6 @@ public:
|
||||||
|
|
||||||
//! Check if transaction will be final given chain height current time.
|
//! Check if transaction will be final given chain height current time.
|
||||||
virtual bool checkFinalTx(const CTransaction& tx) = 0;
|
virtual bool checkFinalTx(const CTransaction& tx) = 0;
|
||||||
|
|
||||||
//! Add transaction to memory pool if the transaction fee is below the
|
|
||||||
//! amount specified by absurd_fee. Returns false if the transaction
|
|
||||||
//! could not be added due to the fee or for another reason.
|
|
||||||
virtual bool submitToMemoryPool(const CTransactionRef& tx, CAmount absurd_fee, CValidationState& state) = 0;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
//! Return Lock interface. Chain is locked when this is called, and
|
//! Return Lock interface. Chain is locked when this is called, and
|
||||||
|
@ -164,9 +155,6 @@ public:
|
||||||
//! Check if transaction has descendants in mempool.
|
//! Check if transaction has descendants in mempool.
|
||||||
virtual bool hasDescendantsInMempool(const uint256& txid) = 0;
|
virtual bool hasDescendantsInMempool(const uint256& txid) = 0;
|
||||||
|
|
||||||
//! Relay transaction.
|
|
||||||
virtual void relayTransaction(const uint256& txid) = 0;
|
|
||||||
|
|
||||||
//! Transaction is added to memory pool, if the transaction fee is below the
|
//! Transaction is added to memory pool, if the transaction fee is below the
|
||||||
//! amount specified by max_tx_fee, and broadcast to all peers if relay is set to true.
|
//! amount specified by max_tx_fee, and broadcast to all peers if relay is set to true.
|
||||||
//! Return false if the transaction could not be added due to the fee or for another reason.
|
//! Return false if the transaction could not be added due to the fee or for another reason.
|
||||||
|
|
Loading…
Add table
Reference in a new issue