boost.png (6897 bytes)

PrevUpHomeNext

Class template acceptor_impl<ConnectionSynchronisation, Demultiplexer, non_blocking_synchronisation, SocketErrorPolicy, EventHandler>

boost::net::socket::acceptor_impl<ConnectionSynchronisation, Demultiplexer, non_blocking_synchronisation, SocketErrorPolicy, EventHandler> — non-blocking acceptor for sockets

Synopsis

template<typename ConnectionSynchronisation, typename Demultiplexer, 
         typename SocketErrorPolicy, typename EventHandler> 
class acceptor_impl<ConnectionSynchronisation, Demultiplexer, non_blocking_synchronisation, SocketErrorPolicy, EventHandler> {
public:
  // types
  typedef Demultiplexer                demultiplexer_t;             
  typedef non_blocking_synchronisation synchronisation_t;           
  typedef ConnectionSynchronisation    connection_synchronisation_t;
  typedef SocketErrorPolicy            error_policy;                
  typedef socket                       socket_base_t;               
  typedef socket                       ipc_t;                       
  typedef boost::net::socket::socket_t os_socket_t;                 
  typedef any_address                  address_t;                   

  // construct/copy/destruct
  acceptor_impl& operator=(const acceptor_impl &);

  // public member functions
   acceptor_impl(Demultiplexer &) ;
   ~acceptor_impl() ;
  template<typename Endpoint> 
    acceptor_error open(const Endpoint &, std::size_t = 1) ;
  template<typename SocketOption> acceptor_error setsockopt(SocketOption &) ;
  bool can_accept() ;
  acceptor_error accept() ;
  Demultiplexer & demultiplexer() ;

  // private member functions
  acceptor_error close() ;
};

Description

acceptor_impl construct/copy/destruct

  1. acceptor_impl& operator=(const acceptor_impl & );

acceptor_impl public member functions

  1.  acceptor_impl(Demultiplexer & demux) ;
  2.  ~acceptor_impl() ;
  3. template<typename Endpoint> 
      acceptor_error open(const Endpoint & endpoint, std::size_t backlog = 1) ;

    Non-blocking version

  4. template<typename SocketOption> 
      acceptor_error setsockopt(SocketOption & option) ;
  5. bool can_accept() ;
  6. acceptor_error accept() ;
  7. Demultiplexer & demultiplexer() ;

acceptor_impl private member functions

  1. acceptor_error close() ;

    process any events generated by shutdown

    process any events generated by close

Copyright © 2004 Hugo Duncan

PrevUpHomeNext