Local acceptor.
More...
#include <acceptor.hpp>
|
using | socket_type = typename boost::asio::local::stream_protocol::acceptor ::protocol_type::socket |
|
using | handler = std::function< void(std::error_code, std::shared_ptr< stream >)> |
| Accept completion handler. More...
|
|
boost::asio::io_context & | service_ |
| The I/O context. More...
|
|
boost::asio::local::stream_protocol::acceptor | acceptor_ |
| The underlying acceptor. More...
|
|
Local acceptor.
- Note
- Only available if BOOST_ASIO_HAS_LOCAL_SOCKETS is defined
◆ local_acceptor()
irccd::local_acceptor::local_acceptor |
( |
boost::asio::io_context & |
service, |
|
|
const boost::filesystem::path & |
path |
|
) |
| |
|
inline |
Construct a local acceptor.
- Parameters
-
service | the I/O service |
path | the unix socket file |
◆ accept() [1/2]
void irccd::local_acceptor::accept |
( |
handler |
handler | ) |
|
|
inlineoverridevirtual |
Start asynchronous accept.
Once the client is accepted, the original acceptor must be kept until it is destroyed.
- Precondition
- another accept operation must not be running
-
handler != nullptr
- Parameters
-
Implements irccd::acceptor.
◆ accept() [2/2]
template<typename Socket , typename Handler >
◆ basic_socket_acceptor() [1/2]
◆ basic_socket_acceptor() [2/2]
The documentation for this class was generated from the following file: