2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
42#ifndef NET_IN6_STREAM_SOCKETSERVER_H
43#define NET_IN6_STREAM_SOCKETSERVER_H
45#include "core/socket/stream/SocketServer.h"
46#include "net/in6/phy/stream/PhysicalSocketServer.h"
48#ifndef DOXYGEN_SHOULD_SKIP_THIS
56namespace net::in6::stream {
58 template <
template <
typename PhysicalSocketServer,
typename ConfigSocketServer>
typename SocketAcceptorT,
59 typename ConfigSocketServerT,
60 typename SocketContextFactoryT,
75 void listen(uint16_t port,
const std::function<
void(
const SocketAddress&, core::socket::State)>& onStatus)
const {
76 Super::getConfig().Local::setPort(port);
80 void listen(uint16_t port,
int backlog,
const std::function<
void(
const SocketAddress&, core::socket::State)>& onStatus)
const {
81 Super::getConfig().Local::setPort(port);
82 Super::getConfig().setBacklog(backlog);
87 void listen(
const std::string& ipOrHostname,
89 const std::function<
void(
const SocketAddress&, core::socket::State)>& onStatus)
const {
90 Super::getConfig().Local::setHost(ipOrHostname).setPort(port);
95 void listen(
const std::string& ipOrHostname,
98 const std::function<
void(
const SocketAddress&, core::socket::State)>& onStatus)
const {
99 Super::getConfig().Local::setHost(ipOrHostname).setPort(port);
100 Super::getConfig().setBacklog(backlog);
#define APPLICATION(req, res)
static void init(int argc, char *argv[])
static int start(const utils::Timeval &timeOut={LONG_MAX, 0})
void listen(const std::string &ipOrHostname, uint16_t port, const std::function< void(const SocketAddress &, core::socket::State)> &onStatus) const
void listen(uint16_t port, int backlog, const std::function< void(const SocketAddress &, core::socket::State)> &onStatus) const
void listen(uint16_t port, const std::function< void(const SocketAddress &, core::socket::State)> &onStatus) const
void listen(const std::string &ipOrHostname, uint16_t port, int backlog, const std::function< void(const SocketAddress &, core::socket::State)> &onStatus) const
int main(int argc, char *argv[])
Router getRouter(const std::string &webRoot)