5 #ifndef BITCOIN_NODE_KERNEL_NOTIFICATIONS_H 6 #define BITCOIN_NODE_KERNEL_NOTIFICATIONS_H 36 void flushError(
const std::string& debug_message)
override;
52 #endif // BITCOIN_NODE_KERNEL_NOTIFICATIONS_H
void ReadNotificationArgs(const ArgsManager &args, KernelNotifications ¬ifications)
SynchronizationState
Current sync state passed to tip changed callbacks.
std::variant< std::monostate, Interrupted > InterruptResult
Simple result type for functions that need to propagate an interrupt status and don't have other retu...
static constexpr int DEFAULT_STOPATHEIGHT
void progress(const bilingual_str &title, int progress_percent, bool resume_possible) override
void flushError(const std::string &debug_message) override
The flush error notification is sent to notify the user that an error occurred while flushing block d...
A base class defining functions for notifying about certain kernel events.
void warning(const bilingual_str &warning) override
kernel::InterruptResult blockTip(SynchronizationState state, CBlockIndex &index) override
KernelNotifications(std::atomic< int > &exit_status)
void headerTip(SynchronizationState state, int64_t height, int64_t timestamp, bool presync) override
The block chain is a tree shaped structure starting with the genesis block at the root...
void fatalError(const std::string &debug_message, const bilingual_str &user_message={}) override
The fatal error notification is sent to notify the user when an error occurs in kernel code that can'...
std::atomic< int > & m_exit_status
int m_stop_at_height
Block height after which blockTip notification will return Interrupted{}, if >0.
bool m_shutdown_on_fatal_error
Useful for tests, can be set to false to avoid shutdown on fatal error.