Changeset View
Changeset View
Standalone View
Standalone View
src/index/base.h
Show First 20 Lines • Show All 58 Lines • ▼ Show 20 Lines | private: | ||||
/// index, the index can continue processing without risk of corruption, | /// index, the index can continue processing without risk of corruption, | ||||
/// though the index state will need to catch up from further behind on | /// though the index state will need to catch up from further behind on | ||||
/// reboot. If the new state is not a successor of the previous state (due | /// reboot. If the new state is not a successor of the previous state (due | ||||
/// to a chain reorganization), the index must halt until Commit succeeds or | /// to a chain reorganization), the index must halt until Commit succeeds or | ||||
/// else it could end up getting corrupted. | /// else it could end up getting corrupted. | ||||
bool Commit(); | bool Commit(); | ||||
protected: | protected: | ||||
void | void BlockConnected(const std::shared_ptr<const CBlock> &block, | ||||
BlockConnected(const std::shared_ptr<const CBlock> &block, | const CBlockIndex *pindex) override; | ||||
const CBlockIndex *pindex, | |||||
const std::vector<CTransactionRef> &txn_conflicted) override; | |||||
void ChainStateFlushed(const CBlockLocator &locator) override; | void ChainStateFlushed(const CBlockLocator &locator) override; | ||||
/// Initialize internal state from the database and block index. | /// Initialize internal state from the database and block index. | ||||
virtual bool Init(); | virtual bool Init(); | ||||
/// Write update index entries for a newly connected block. | /// Write update index entries for a newly connected block. | ||||
virtual bool WriteBlock(const CBlock &block, const CBlockIndex *pindex) { | virtual bool WriteBlock(const CBlock &block, const CBlockIndex *pindex) { | ||||
Show All 39 Lines |