blob: 918bde9b17e5995db451888d3bd06ea09b00caef (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
#ifndef NET_HH
#define NET_HH
#include <cstdint>
#include <string>
#include <vector>
#include "logger.hh"
#include "unique_fd.hh"
namespace net {
std::vector<unique_fd> bind_and_listen(
Logger* logger, std::string const& host, uint16_t port);
unique_fd connect(Logger* logger, std::string const& host, uint16_t port);
unique_fd accept(Logger* logger, int fd);
} // namespace net
#endif // NET_HH
|