Kagome
Polkadot Runtime Engine in C++17
|
server which listens for incoming connection, accepts connections making session from socket More...
#include <listener.hpp>
Classes | |
struct | Configuration |
Public Types | |
using | Context = RpcContext |
Public Member Functions | |
virtual | ~Listener ()=default |
virtual bool | prepare ()=0 |
Bind endpoint. More... | |
virtual bool | start ()=0 |
Start handling inner connection. More... | |
virtual void | stop ()=0 |
Stop working. More... | |
virtual void | setHandlerForNewSession (NewSessionHandler &&on_new_session)=0 |
Set handler for working new session. More... | |
Protected Types | |
using | Acceptor = boost::asio::ip::tcp::acceptor |
using | Endpoint = boost::asio::ip::tcp::endpoint |
using | NewSessionHandler = std::function< void(const std::shared_ptr< Session > &)> |
Protected Member Functions | |
virtual void | acceptOnce ()=0 |
Accept incoming connection. More... | |
server which listens for incoming connection, accepts connections making session from socket
Definition at line 21 of file listener.hpp.
|
protected |
Definition at line 23 of file listener.hpp.
Definition at line 29 of file listener.hpp.
|
protected |
Definition at line 24 of file listener.hpp.
|
protected |
Definition at line 26 of file listener.hpp.
|
virtualdefault |
|
protectedpure virtual |
Accept incoming connection.
Implemented in kagome::api::WsListenerImpl, and kagome::api::HttpListenerImpl.
|
pure virtual |
Bind endpoint.
Implemented in kagome::api::WsListenerImpl, and kagome::api::HttpListenerImpl.
|
pure virtual |
Set handler for working new session.
Implemented in kagome::api::WsListenerImpl, and kagome::api::HttpListenerImpl.
|
pure virtual |
Start handling inner connection.
Implemented in kagome::api::WsListenerImpl, and kagome::api::HttpListenerImpl.
|
pure virtual |
Stop working.
Implemented in kagome::api::WsListenerImpl, and kagome::api::HttpListenerImpl.