SNode.C
|
#include <SocketServer.h>
Public Types | |
using | SocketConnection = typename SocketAcceptor::SocketConnection |
using | SocketAddress = typename SocketAcceptor::SocketAddress |
![]() | |
using | Config |
Public Member Functions | |
SocketServer (const std::string &name, const std::function< void(SocketConnection *)> &onConnect, const std::function< void(SocketConnection *)> &onConnected, const std::function< void(SocketConnection *)> &onDisconnect, Args &&... args) | |
SocketServer (const std::function< void(SocketConnection *)> &onConnect, const std::function< void(SocketConnection *)> &onConnected, const std::function< void(SocketConnection *)> &onDisconnect, Args &&... args) | |
SocketServer (const std::string &name, Args &&... args) | |
SocketServer (Args &&... args) | |
void | listen (const std::function< void(const SocketAddress &, core::socket::State)> &onStatus) const |
void | listen (const SocketAddress &localAddress, const std::function< void(const SocketAddress &, core::socket::State)> &onStatus) const |
void | listen (const SocketAddress &localAddress, int backlog, const std::function< void(const SocketAddress &, core::socket::State)> &onStatus) const |
std::function< void(SocketConnection *)> | setOnConnect (const std::function< void(SocketConnection *)> &onConnect) |
std::function< void(SocketConnection *)> | setOnConnected (const std::function< void(SocketConnection *)> &onConnected) |
std::function< void(SocketConnection *)> | setOnDisconnect (const std::function< void(SocketConnection *)> &onDisconnect) |
std::shared_ptr< SocketContextFactory > | getSocketContextFactory () |
![]() | |
Socket (const std::string &name) | |
Socket (const Socket &)=default | |
Socket (Socket &&) noexcept=delete | |
Socket & | operator= (const Socket &)=default |
Socket & | operator= (Socket &&) noexcept=delete |
virtual | ~Socket () |
Config & | getConfig () const |
Private Types | |
using | SocketAcceptor = SocketAcceptorT |
using | SocketContextFactory = SocketContextFactoryT |
using | Super = core::socket::Socket<typename SocketAcceptor::Config> |
Private Member Functions | |
void | realListen (const std::function< void(const SocketAddress &, core::socket::State)> &onStatus, unsigned int tries, double retryTimeoutScale) const |
Private Attributes | |
std::shared_ptr< SocketContextFactory > | socketContextFactory |
std::function< void(SocketConnection *)> | onConnect |
std::function< void(SocketConnection *)> | onConnected |
std::function< void(SocketConnection *)> | onDisconnect |
std::size_t | totalOk = 0 |
std::size_t | currentOk = 0 |
std::size_t | currentError = 0 |
std::size_t | currentFatal = 0 |
Additional Inherited Members | |
![]() | |
std::shared_ptr< Config > | config |
Definition at line 43 of file SocketServer.h.
|
private |
Definition at line 45 of file SocketServer.h.
using core::socket::stream::SocketServer< SocketAcceptorT, SocketContextFactoryT, Args >::SocketAddress = typename SocketAcceptor::SocketAddress |
Definition at line 52 of file SocketServer.h.
using core::socket::stream::SocketServer< SocketAcceptorT, SocketContextFactoryT, Args >::SocketConnection = typename SocketAcceptor::SocketConnection |
Definition at line 51 of file SocketServer.h.
|
private |
Definition at line 46 of file SocketServer.h.
|
private |
Definition at line 48 of file SocketServer.h.
|
inline |
Definition at line 54 of file SocketServer.h.
|
inline |
Definition at line 66 of file SocketServer.h.
|
inline |
Definition at line 74 of file SocketServer.h.
|
inlineexplicit |
Definition at line 98 of file SocketServer.h.
|
inline |
Definition at line 214 of file SocketServer.h.
|
inline |
Definition at line 175 of file SocketServer.h.
|
inline |
Definition at line 182 of file SocketServer.h.
|
inline |
Definition at line 171 of file SocketServer.h.
|
inlineprivate |
Definition at line 103 of file SocketServer.h.
|
inline |
Definition at line 190 of file SocketServer.h.
|
inline |
Definition at line 198 of file SocketServer.h.
|
inline |
Definition at line 206 of file SocketServer.h.
|
private |
Definition at line 227 of file SocketServer.h.
|
private |
Definition at line 228 of file SocketServer.h.
|
private |
Definition at line 226 of file SocketServer.h.
|
private |
Definition at line 221 of file SocketServer.h.
|
private |
Definition at line 222 of file SocketServer.h.
|
private |
Definition at line 223 of file SocketServer.h.
|
private |
Definition at line 219 of file SocketServer.h.
|
private |
Definition at line 225 of file SocketServer.h.