CatapultServer
v0.5.0.1 (Elephant)
|
Establishes connections with external nodes that this (local) node initiates. More...
Public Types | |
using | ConnectCallback = consumer< PeerConnectCode, const std::shared_ptr< ionet::PacketSocket > & > |
A callback that is passed the connect result and the connected socket on success. More... | |
Public Member Functions | |
virtual | ~ServerConnector ()=default |
virtual size_t | numActiveConnections () const =0 |
Gets the number of active connections. More... | |
virtual void | connect (const ionet::Node &node, const ConnectCallback &callback)=0 |
Attempts to connect to node and calls callback on completion. More... | |
virtual void | shutdown ()=0 |
Shuts down all connections. More... | |
Establishes connections with external nodes that this (local) node initiates.
using catapult::net::ServerConnector::ConnectCallback = consumer<PeerConnectCode, const std::shared_ptr<ionet::PacketSocket>&> |
A callback that is passed the connect result and the connected socket on success.
|
virtualdefault |
|
pure virtual |
Attempts to connect to node and calls callback on completion.
|
pure virtual |
Gets the number of active connections.
|
pure virtual |
Shuts down all connections.