For a more detailed usage description and overview please see the main page.
These member functions can only be called from within multiplex_impl
.
◆ wait()
Wait for condition.
Go idle if non of the bits of conditions were signaled twice or more since the last call to wait(
that_bit)
. The task will continue whenever signal(condition)
is called where conditions & condition != 0
.
- Parameters
-
conditions | A bit mask of conditions to wait for. |
◆ wait_until() [1/2]
Block until the wait_condition returns true.
Whenever something changed that might cause wait_condition to return true
, signal(condition)
must be called. Calling signal(condition)
more often is okay.
- Parameters
-
wait_condition | A std::function<bool()> that must return true . |
conditions | A bit mask of conditions to wait for. |
◆ wait_until() [2/2]
Block until the wait_condition returns true.
Whenever something changed that might cause wait_condition to return true
, signal(condition)
must be called. Calling signal(condition)
more often is okay.
- Parameters
-
wait_condition | A std::function<bool()> that must return true . |
conditions | A bit mask of conditions to wait for. |
new_state | The new state to continue with once wait_condition returns true . |