![]() |
PIVX Core
5.6.99
P2P Digital Currency
|
Implement this to subscribe to events generated in validation. More...
#include <validationinterface.h>
Public Member Functions | |
| virtual | ~CValidationInterface ()=default |
| virtual void | AcceptedBlockHeader (const CBlockIndex *pindexNew) |
Protected Member Functions | |
| virtual void | UpdatedBlockTip (const CBlockIndex *pindexNew, const CBlockIndex *pindexFork, bool fInitialDownload) |
| Notifies listeners when the block chain tip advances. More... | |
| virtual void | TransactionAddedToMempool (const CTransactionRef &ptxn) |
| Notifies listeners of a transaction having been added to mempool. More... | |
| virtual void | TransactionRemovedFromMempool (const CTransactionRef &ptx, MemPoolRemovalReason reason) |
| Notifies listeners of a transaction leaving mempool. More... | |
| virtual void | BlockConnected (const std::shared_ptr< const CBlock > &block, const CBlockIndex *pindex) |
| Notifies listeners of a block being connected. More... | |
| virtual void | BlockDisconnected (const std::shared_ptr< const CBlock > &block, const uint256 &blockHash, int nBlockHeight, int64_t blockTime) |
| Notifies listeners of a block being disconnected. More... | |
| virtual void | SetBestChain (const CBlockLocator &locator) |
| Notifies listeners of the new active block chain on-disk. More... | |
| virtual void | ResendWalletTransactions (CConnman *connman) |
| Tells listeners to broadcast their data. More... | |
| virtual void | BlockChecked (const CBlock &, const CValidationState &) |
| friend | void ::RegisterSharedValidationInterface (std::shared_ptr< CValidationInterface >) |
| friend | void ::UnregisterValidationInterface (CValidationInterface *) |
| friend | void ::UnregisterAllValidationInterfaces () |
| virtual void | NotifyMasternodeListChanged (bool undo, const CDeterministicMNList &oldMNList, const CDeterministicMNListDiff &diff) |
| Notifies listeners of updated deterministic masternode list. More... | |
Implement this to subscribe to events generated in validation.
Each CValidationInterface() subscriber will receive event callbacks in the order in which the events were generated by validation. Furthermore, each ValidationInterface() subscriber may assume that callbacks effectively run in a single thread with single-threaded memory consistency. That is, for a given ValidationInterface() instantiation, each callback will complete before the next one is invoked. This means, for example when a block is connected that the UpdatedBlockTip() callback may depend on an operation performed in the BlockConnected() callback without worrying about explicit synchronization. No ordering should be assumed across ValidationInterface() subscribers.
Definition at line 81 of file validationinterface.h.
|
virtualdefault |
|
inlinevirtual |
Reimplemented in EvoNotificationInterface.
Definition at line 84 of file validationinterface.h.
|
inlineprotectedvirtual |
Reimplemented in BlockStateCatcher, and PeerLogicValidation.
Definition at line 157 of file validationinterface.h.
|
inlineprotectedvirtual |
Notifies listeners of a block being connected.
Provides a vector of transactions evicted from the mempool as a result.
Called on a background thread.
Reimplemented in CZMQNotificationInterface, CWallet, PeerLogicValidation, and TestSubscriber.
Definition at line 142 of file validationinterface.h.
|
inlineprotectedvirtual |
Notifies listeners of a block being disconnected.
Called on a background thread.
Reimplemented in CZMQNotificationInterface, CWallet, and TestSubscriber.
Definition at line 148 of file validationinterface.h.
|
inlineprotectedvirtual |
Notifies listeners of updated deterministic masternode list.
Reimplemented in EvoNotificationInterface.
Definition at line 162 of file validationinterface.h.
|
inlineprotectedvirtual |
Tells listeners to broadcast their data.
Reimplemented in CWallet.
Definition at line 156 of file validationinterface.h.
|
inlineprotectedvirtual |
Notifies listeners of the new active block chain on-disk.
Called on a background thread.
Reimplemented in CWallet.
Definition at line 154 of file validationinterface.h.
|
inlineprotectedvirtual |
Notifies listeners of a transaction having been added to mempool.
Called on a background thread.
Reimplemented in CZMQNotificationInterface, and CWallet.
Definition at line 102 of file validationinterface.h.
|
inlineprotectedvirtual |
Notifies listeners of a transaction leaving mempool.
This notification fires for transactions that are removed from the mempool for the following reasons:
This does not fire for transactions that are removed from the mempool because they have been included in a block. Any client that is interested in transactions removed from the mempool for inclusion in a block can learn about those transactions from the BlockConnected notification.
Transactions that are removed from the mempool because they conflict with a transaction in the new block will have TransactionRemovedFromMempool events fired before the BlockConnected event is fired. If multiple blocks are connected in one step, then the ordering could be:
Called on a background thread.
Reimplemented in CWallet.
Definition at line 135 of file validationinterface.h.
|
inlineprotectedvirtual |
Notifies listeners when the block chain tip advances.
When multiple blocks are connected at once, UpdatedBlockTip will be called on the final tip but may not be called on every intermediate tip. If the latter behavior is desired, subscribe to BlockConnected() instead.
Called on a background thread.
Reimplemented in CZMQNotificationInterface, CWallet, PeerLogicValidation, CMasternodePayments, EvoNotificationInterface, CBudgetManager, CActiveDeterministicMasternodeManager, and TestSubscriber.
Definition at line 96 of file validationinterface.h.
|
protected |
|
protected |
|
protected |