asio C++ library

PrevUpHomeNext
io_service::run_one (2 of 2 overloads)

Run the io_service object's event processing loop to execute at most one handler.

std::size_t run_one(
    asio::error_code & ec);

The run_one() function blocks until one handler has been dispatched, or until the io_service has been stopped.

Return Value

The number of handlers that were executed. A zero return value implies that the io_service object is stopped (the stopped() function returns true). Subsequent calls to run(), run_one(), poll() or poll_one() will return immediately unless there is a prior call to reset().

The number of handlers that were executed.


PrevUpHomeNext