Dash Core Source Documentation (0.16.0.1)
Find detailed information regarding the Dash Core source code.
clientmodel.cpp
Go to the documentation of this file.
153 return QDateTime::fromTime_t(Params().GenesisBlock().GetBlockTime()); // Genesis block's time of current network
163 return QString::fromStdString(Params().GenesisBlock().GetHash().ToString()); // Genesis block's hash of current network
334 static void BlockTipChanged(ClientModel *clientmodel, bool initialSync, const CBlockIndex *pIndex, bool fHeader)
343 int64_t& nLastUpdateNotification = fHeader ? nLastHeaderTipUpdateNotification : nLastBlockTipUpdateNotification;
363 static void NotifyMasternodeListChanged(ClientModel *clientmodel, const CDeterministicMNList& newList)
368 static void NotifyAdditionalDataSyncProgressChanged(ClientModel *clientmodel, double nSyncProgress)
370 QMetaObject::invokeMethod(clientmodel, "additionalDataSyncProgressChanged", Qt::QueuedConnection,
378 uiInterface.NotifyNumConnectionsChanged.connect(boost::bind(NotifyNumConnectionsChanged, this, _1));
379 uiInterface.NotifyNetworkActiveChanged.connect(boost::bind(NotifyNetworkActiveChanged, this, _1));
384 uiInterface.NotifyMasternodeListChanged.connect(boost::bind(NotifyMasternodeListChanged, this, _1));
385 uiInterface.NotifyAdditionalDataSyncProgressChanged.connect(boost::bind(NotifyAdditionalDataSyncProgressChanged, this, _1));
392 uiInterface.NotifyNumConnectionsChanged.disconnect(boost::bind(NotifyNumConnectionsChanged, this, _1));
393 uiInterface.NotifyNetworkActiveChanged.disconnect(boost::bind(NotifyNetworkActiveChanged, this, _1));
398 uiInterface.NotifyMasternodeListChanged.disconnect(boost::bind(NotifyMasternodeListChanged, this, _1));
399 uiInterface.NotifyAdditionalDataSyncProgressChanged.disconnect(boost::bind(NotifyAdditionalDataSyncProgressChanged, this, _1));
QString formatClientStartupTime() const
Definition: clientmodel.cpp:285
CTxMemPool mempool
Definition: clientmodel.h:31
void updateNetworkActive(bool networkActive)
Definition: clientmodel.cpp:208
bool inInitialBlockDownload() const
Return true if core is doing initial block download.
Definition: clientmodel.cpp:218
static void NotifyAlertChanged(ClientModel *clientmodel)
Definition: clientmodel.cpp:322
long getMempoolSize() const
Return number of transactions in the mempool.
Definition: clientmodel.cpp:166
bool getNetworkActive() const
Return true if network activity in core is enabled.
Definition: clientmodel.cpp:242
Definition: clientmodel.h:29
std::atomic< int64_t > cachedBestHeaderTime
Definition: clientmodel.h:96
void setMasternodeList(const CDeterministicMNList &mnList)
Definition: clientmodel.cpp:78
boost::signals2::signal< void(bool networkActive)> NotifyNetworkActiveChanged
Network activity state changed.
Definition: ui_interface.h:88
static void ShowProgress(ClientModel *clientmodel, const std::string &title, int nProgress)
Definition: clientmodel.cpp:301
void networkActiveChanged(bool networkActive)
std::atomic< int > cachedBestHeaderHeight
Definition: clientmodel.h:95
std::string GetWarnings(const std::string &strFor)
Format a string that describes several potential problems detected by the core.
Definition: warnings.cpp:41
void masternodeListChanged() const
static void BlockTipChanged(ClientModel *clientmodel, bool initialSync, const CBlockIndex *pIndex, bool fHeader)
Definition: clientmodel.cpp:334
std::unique_ptr< CDeterministicMNManager > deterministicMNManager
Definition: deterministicmns.cpp:24
static void NotifyAdditionalDataSyncProgressChanged(ClientModel *clientmodel, double nSyncProgress)
Definition: clientmodel.cpp:368
void numConnectionsChanged(int count)
boost::signals2::signal< void(double nSyncProgress)> NotifyAdditionalDataSyncProgressChanged
Additional data sync progress changed.
Definition: ui_interface.h:114
QString getStatusBarWarnings() const
Return warnings to be displayed in status bar.
Definition: clientmodel.cpp:250
void alertsChanged(const QString &warnings)
Definition: clientmodel.h:37
CInstantSendManager * quorumInstantSendManager
Definition: quorums_instantsend.cpp:40
boost::signals2::signal< void(void)> BannedListChanged
Banlist did change.
Definition: ui_interface.h:117
boost::signals2::signal< void(bool, const CBlockIndex *)> NotifyBlockTip
New block has been accepted.
Definition: ui_interface.h:105
boost::signals2::signal< void(bool, const CBlockIndex *)> NotifyHeaderTip
Best header has changed.
Definition: ui_interface.h:108
Definition: net.h:145
Definition: clientmodel.h:36
static int64_t nLastHeaderTipUpdateNotification
Definition: clientmodel.cpp:36
Definition: deterministicmns.h:288
const uint256 & GetBlockHash() const
Definition: deterministicmns.h:376
int getNumConnections(unsigned int flags=CONNECTIONS_ALL) const
Return number of connections, default is in- and outbound (total)
Definition: clientmodel.cpp:62
double getVerificationProgress(const CBlockIndex *tip) const
Definition: clientmodel.cpp:184
enum BlockSource getBlockSource() const
Returns enum BlockSource of the current importing/syncing state.
Definition: clientmodel.cpp:223
CBlockIndex * pindexBestHeader
Best header we've seen so far (used for getheaders queries' starting points).
Definition: validation.cpp:218
Qt model providing information about connected peers, similar to the "getpeerinfo" RPC call...
Definition: peertablemodel.h:45
void unsubscribeFromCoreSignals()
Definition: clientmodel.cpp:388
boost::signals2::signal< void(const CDeterministicMNList &)> NotifyMasternodeListChanged
Masternode list has changed.
Definition: ui_interface.h:111
bool IsInitialBlockDownload()
Check whether we are doing an initial block download (synchronizing from disk or network) ...
Definition: validation.cpp:1219
std::atomic_bool fImporting
CDeterministicMNList getMasternodeList() const
Definition: clientmodel.cpp:88
void islockCountChanged(size_t count)
std::string strSubVersion
Subversion as sent to the P2P network in version messages.
Definition: net.cpp:118
Definition: clientmodel.h:28
static void NotifyMasternodeListChanged(ClientModel *clientmodel, const CDeterministicMNList &newList)
Definition: clientmodel.cpp:363
size_t getMempoolDynamicUsage() const
Return the dynamic memory usage of the mempool.
Definition: clientmodel.cpp:171
Definition: net.h:144
Definition: clientmodel.h:38
boost::signals2::signal< void(int newNumConnections)> NotifyNumConnectionsChanged
Number of network connections changed.
Definition: ui_interface.h:85
static void BannedListChanged(ClientModel *clientmodel)
Definition: clientmodel.cpp:328
std::atomic_bool fReindex
size_t GetInstantSendLockCount()
Definition: quorums_instantsend.cpp:1499
ClientModel(OptionsModel *optionsModel, QObject *parent=0)
Definition: clientmodel.cpp:39
Interface from Qt to configuration data structure for Bitcoin client.
Definition: optionsmodel.h:25
The block chain is a tree shaped structure starting with the genesis block at the root...
Definition: chain.h:170
const CChainParams & Params()
Return the currently selected parameters.
Definition: chainparams.cpp:947
boost::signals2::signal< void()> NotifyAlertChanged
Status bar alerts changed.
Definition: ui_interface.h:93
static int64_t nLastBlockTipUpdateNotification
Definition: clientmodel.cpp:37
double GuessVerificationProgress(const ChainTxData &data, const CBlockIndex *pindex)
Guess how far we are in the verification process at the given block index.
Definition: validation.cpp:5035
Qt model providing information about connected peers, similar to the "getpeerinfo" RPC call...
Definition: bantablemodel.h:39
Definition: clientmodel.h:30
static void NotifyNetworkActiveChanged(ClientModel *clientmodel, bool networkActive)
Definition: clientmodel.cpp:316
CBlockIndex * Tip() const
Returns the index entry for the tip of this chain, or nullptr if none.
Definition: chain.h:453
void mempoolSizeChanged(long count, size_t mempoolSizeInBytes)
void setNetworkActive(bool active)
Toggle network activity state in core.
Definition: clientmodel.cpp:235
Definition: net.h:142
void updateNumConnections(int numConnections)
Definition: clientmodel.cpp:203
CChain & chainActive
The currently-connected chain of blocks (protected by cs_main).
Definition: validation.cpp:217
QString boostPathToQString(const fs::path &path)
Definition: guiutil.cpp:1828
static void NotifyNumConnectionsChanged(ClientModel *clientmodel, int newNumConnections)
Definition: clientmodel.cpp:309
boost::signals2::signal< void(const std::string &title, int nProgress, bool resume_possible)> ShowProgress
Show progress e.g.
Definition: ui_interface.h:102
Definition: net.h:143