asio C++ library

PrevUpHomeNext

make_work_guard (2 of 5 overloads)

Create an executor_work_guard object.

template<
    typename ExecutionContext>
executor_work_guard< typename ExecutionContext::executor_type > make_work_guard(
    ExecutionContext & ctx,
    constraint_t< is_convertible< ExecutionContext &, execution_context & >::value >  = 0);
Parameters

ctx

An execution context, from which an executor will be obtained.

Return Value

A work guard constructed with the execution context's executor, obtained by performing ctx.get_executor().


PrevUpHomeNext