mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-10 22:18:54 +01:00
refactor: remove unused assumeutxo methods
After feedback from Russ, I realized that there are some extraneous assumeutxo methods that are not necessary and probably just overly confusing. These include - `Validated*()` - `IsBackgroundIBD()` and they can be removed.
This commit is contained in:
@@ -862,12 +862,6 @@ private:
|
||||
* *Background IBD chainstate*: an IBD chainstate for which the
|
||||
* IBD process is happening in the background while use of the
|
||||
* active (snapshot) chainstate allows the rest of the system to function.
|
||||
*
|
||||
* *Validated chainstate*: the most-work chainstate which has been validated
|
||||
* locally via initial block download. This will be the snapshot chainstate
|
||||
* if a snapshot was loaded and all blocks up to the snapshot starting point
|
||||
* have been downloaded and validated (via background validation), otherwise
|
||||
* it will be the IBD chainstate.
|
||||
*/
|
||||
class ChainstateManager
|
||||
{
|
||||
@@ -986,19 +980,6 @@ public:
|
||||
//! Is there a snapshot in use and has it been fully validated?
|
||||
bool IsSnapshotValidated() const { return m_snapshot_validated; }
|
||||
|
||||
//! @returns true if this chainstate is being used to validate an active
|
||||
//! snapshot in the background.
|
||||
bool IsBackgroundIBD(CChainState* chainstate) const;
|
||||
|
||||
//! Return the most-work chainstate that has been fully validated.
|
||||
//!
|
||||
//! During background validation of a snapshot, this is the IBD chain. After
|
||||
//! background validation has completed, this is the snapshot chain.
|
||||
CChainState& ValidatedChainstate() const;
|
||||
|
||||
CChain& ValidatedChain() const { return ValidatedChainstate().m_chain; }
|
||||
CBlockIndex* ValidatedTip() const { return ValidatedChain().Tip(); }
|
||||
|
||||
/**
|
||||
* Process an incoming block. This only returns after the best known valid
|
||||
* block is made active. Note that it does not, however, guarantee that the
|
||||
|
||||
Reference in New Issue
Block a user