Changeset View
Changeset View
Standalone View
Standalone View
src/interfaces/chain.h
Show First 20 Lines • Show All 43 Lines • ▼ Show 20 Lines | |||||
//! internal workings of the bitcoin node, and not being very convenient to use. | //! internal workings of the bitcoin node, and not being very convenient to use. | ||||
//! Chain methods should be cleaned up and simplified over time. Examples: | //! Chain methods should be cleaned up and simplified over time. Examples: | ||||
//! | //! | ||||
//! * The Chain::lock() method, which lets clients delay chain tip updates | //! * The Chain::lock() method, which lets clients delay chain tip updates | ||||
//! should be removed when clients are able to respond to updates | //! should be removed when clients are able to respond to updates | ||||
//! asynchronously | //! asynchronously | ||||
//! (https://github.com/bitcoin/bitcoin/pull/10973#issuecomment-380101269). | //! (https://github.com/bitcoin/bitcoin/pull/10973#issuecomment-380101269). | ||||
//! | //! | ||||
//! * The initMessages() and loadWallet() methods which the wallet uses to send | //! * The initMessage() and showProgress() 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 | ||||
//! (https://github.com/bitcoin/bitcoin/pull/15288#discussion_r253321096). | //! (https://github.com/bitcoin/bitcoin/pull/15288#discussion_r253321096). | ||||
//! | //! | ||||
//! * The handleRpc, registerRpcs, rpcEnableDeprecated methods and other RPC | //! * The handleRpc, registerRpcs, rpcEnableDeprecated methods and other RPC | ||||
//! methods can go away if wallets listen for HTTP requests on their own | //! methods can go away if wallets listen for HTTP requests on their own | ||||
//! ports instead of registering to handle requests on the node HTTP port. | //! ports instead of registering to handle requests on the node HTTP port. | ||||
class Chain { | class Chain { | ||||
▲ Show 20 Lines • Show All 149 Lines • ▼ Show 20 Lines | public: | ||||
virtual void initMessage(const std::string &message) = 0; | virtual void initMessage(const std::string &message) = 0; | ||||
//! Send init warning. | //! Send init warning. | ||||
virtual void initWarning(const std::string &message) = 0; | virtual void initWarning(const std::string &message) = 0; | ||||
//! Send init error. | //! Send init error. | ||||
virtual void initError(const std::string &message) = 0; | virtual void initError(const std::string &message) = 0; | ||||
//! Send wallet load notification to the GUI. | |||||
virtual void loadWallet(std::unique_ptr<Wallet> wallet) = 0; | |||||
//! Send progress indicator. | //! Send progress indicator. | ||||
virtual void showProgress(const std::string &title, int progress, | virtual void showProgress(const std::string &title, int progress, | ||||
bool resume_possible) = 0; | bool resume_possible) = 0; | ||||
//! Chain notifications. | //! Chain notifications. | ||||
class Notifications { | class Notifications { | ||||
public: | public: | ||||
virtual ~Notifications() {} | virtual ~Notifications() {} | ||||
▲ Show 20 Lines • Show All 88 Lines • Show Last 20 Lines |