boost.png (6897 bytes)

PrevUpHomeNext

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

boost::net::socket::acceptor_impl<ConnectionSynchronisation, Demultiplexer, asynch_synchronisation, SocketErrorPolicy, EventHandler> — asynch acceptor for sockets

Synopsis

template<typename ConnectionSynchronisation, typename Demultiplexer, 
         typename SocketErrorPolicy, typename EventHandler> 
class acceptor_impl<ConnectionSynchronisation, Demultiplexer, asynch_synchronisation, SocketErrorPolicy, EventHandler> {
public:
  // types
  typedef Demultiplexer                                                                                                      demultiplexer_t;             
  typedef asynch_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;                   
  typedef acceptor_impl< ConnectionSynchronisation, Demultiplexer, asynch_synchronisation, SocketErrorPolicy, EventHandler > self_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 &) ;
  void thread_acceptor(socket_t) ;
  acceptor_error accept() ;

  // private member functions
  void accept_complete_1() ;
  void accept_complete_2(arguments_ptr_type, socket_t) ;
  void accept_complete(socket_t) ;
  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) ;

    we should find a way to control access to this

  4. template<typename SocketOption> 
      acceptor_error setsockopt(SocketOption & option) ;
  5. void thread_acceptor(socket_t os_socket) ;
  6. acceptor_error accept() ;

    accepted socket

acceptor_impl private member functions

  1. void accept_complete_1() ;
  2. void accept_complete_2(arguments_ptr_type arguments, socket_t os_socket) ;
  3. void accept_complete(socket_t os_socket) ;
  4. acceptor_error close() ;
Copyright © 2004 Hugo Duncan

PrevUpHomeNext