Changeset View
Changeset View
Standalone View
Standalone View
src/net.h
Show First 20 Lines • Show All 247 Lines • ▼ Show 20 Lines | void Stop() { | ||||
StopThreads(); | StopThreads(); | ||||
StopNodes(); | StopNodes(); | ||||
}; | }; | ||||
void Interrupt(); | void Interrupt(); | ||||
bool GetNetworkActive() const { return fNetworkActive; }; | bool GetNetworkActive() const { return fNetworkActive; }; | ||||
bool GetUseAddrmanOutgoing() const { return m_use_addrman_outgoing; }; | bool GetUseAddrmanOutgoing() const { return m_use_addrman_outgoing; }; | ||||
void SetNetworkActive(bool active); | void SetNetworkActive(bool active); | ||||
void OpenNetworkConnection( | void OpenNetworkConnection(const CAddress &addrConnect, bool fCountFailure, | ||||
const CAddress &addrConnect, bool fCountFailure, | CSemaphoreGrant *grantOutbound, | ||||
CSemaphoreGrant *grantOutbound = nullptr, const char *strDest = nullptr, | const char *strDest, ConnectionType conn_type); | ||||
ConnectionType conn_type = ConnectionType::OUTBOUND_FULL_RELAY); | |||||
bool CheckIncomingNonce(uint64_t nonce); | bool CheckIncomingNonce(uint64_t nonce); | ||||
bool ForNode(NodeId id, std::function<bool(CNode *pnode)> func); | bool ForNode(NodeId id, std::function<bool(CNode *pnode)> func); | ||||
void PushMessage(CNode *pnode, CSerializedNetMsg &&msg); | void PushMessage(CNode *pnode, CSerializedNetMsg &&msg); | ||||
template <typename Callable> void ForEachNode(Callable &&func) { | template <typename Callable> void ForEachNode(Callable &&func) { | ||||
LOCK(cs_vNodes); | LOCK(cs_vNodes); | ||||
▲ Show 20 Lines • Show All 975 Lines • Show Last 20 Lines |