diff options
Diffstat (limited to 'src/net_processing.h')
-rw-r--r-- | src/net_processing.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/net_processing.h b/src/net_processing.h index f8d7a8f511..85e399d948 100644 --- a/src/net_processing.h +++ b/src/net_processing.h @@ -9,6 +9,8 @@ #include <net.h> #include <validationinterface.h> +#include <chrono> + class AddrMan; class CChainParams; class CTxMemPool; @@ -41,6 +43,12 @@ struct CNodeStateStats { bool m_addr_relay_enabled{false}; ServiceFlags their_services; int64_t presync_height{-1}; + std::chrono::seconds time_offset{0}; +}; + +struct PeerManagerInfo { + std::chrono::seconds median_outbound_time_offset{0s}; + bool ignores_incoming_txs{false}; }; class PeerManager : public CValidationInterface, public NetEventsInterface @@ -83,8 +91,8 @@ public: /** Get statistics from node state */ virtual bool GetNodeStateStats(NodeId nodeid, CNodeStateStats& stats) const = 0; - /** Whether this node ignores txs received over p2p. */ - virtual bool IgnoresIncomingTxs() = 0; + /** Get peer manager info. */ + virtual PeerManagerInfo GetInfo() const = 0; /** Relay transaction to all peers. */ virtual void RelayTransaction(const uint256& txid, const uint256& wtxid) = 0; |