Kea  1.9.9-git
isc::asiolink::UnixDomainSocketAcceptor Class Reference

Implements acceptor service for UnixDomainSocket. More...

#include <unix_domain_socket_acceptor.h>

+ Inheritance diagram for isc::asiolink::UnixDomainSocketAcceptor:

Public Types

typedef std::function< void(const boost::system::error_code &)> AcceptHandler
 Callback type used in call to UnixDomainSocketAcceptor::asyncAccept. More...

Public Member Functions

 UnixDomainSocketAcceptor (IOService &io_service)
 Constructor. More...
void asyncAccept (const UnixDomainSocket &socket, const AcceptHandler &callback)
 Asynchronously accept new connection. More...
virtual int getProtocol () const final
 Returns the transport protocol of the socket. More...

Additional Inherited Members

Detailed Description

Implements acceptor service for UnixDomainSocket.

This class is used to accept new incoming connections over unix domain sockets.

Definition at line 25 of file unix_domain_socket_acceptor.h.

Member Typedef Documentation

typedef std::function<void(const boost::system::error_code&)> isc::asiolink::UnixDomainSocketAcceptor::AcceptHandler

Callback type used in call to UnixDomainSocketAcceptor::asyncAccept.

Definition at line 30 of file unix_domain_socket_acceptor.h.

Constructor & Destructor Documentation

isc::asiolink::UnixDomainSocketAcceptor::UnixDomainSocketAcceptor ( IOService io_service)


io_serviceReference to the IO service.

Definition at line 35 of file unix_domain_socket_acceptor.h.

Member Function Documentation

void isc::asiolink::UnixDomainSocketAcceptor::asyncAccept ( const UnixDomainSocket socket,
const AcceptHandler callback 

Asynchronously accept new connection.

This method accepts new connection into the specified socket. When the new connection arrives or an error occurs the specified callback function is invoked.

socketSocket into which connection should be accepted.
callbackCallback function to be invoked when the new connection arrives.
Template Parameters

Definition at line 57 of file unix_domain_socket_acceptor.h.

References isc::asiolink::IOAcceptor< boost::asio::local::stream_protocol, std::function< void(const boost::system::error_code &)> >::asyncAcceptInternal().

+ Here is the call graph for this function:

virtual int isc::asiolink::UnixDomainSocketAcceptor::getProtocol ( ) const

Returns the transport protocol of the socket.


Implements isc::asiolink::IOSocket.

Definition at line 43 of file unix_domain_socket_acceptor.h.

The documentation for this class was generated from the following file: