Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of Boost. Click here to view this page for the latest version.
PrevUpHomeNext
basic_socket_acceptor::wait (1 of 2 overloads)

Wait for the acceptor to become ready to read, ready to write, or to have pending error conditions.

void wait(
    wait_type w);

This function is used to perform a blocking wait for an acceptor to enter a ready to read, write or error condition state.

Parameters

w

Specifies the desired acceptor state.

Example

Waiting for an acceptor to become readable.

boost::asio::ip::tcp::acceptor acceptor(my_context);
...
acceptor.wait(boost::asio::ip::tcp::acceptor::wait_read);

PrevUpHomeNext