std::experimental::latch (3) - Linux Manuals
std::experimental::latch: std::experimental::latch
NAME
std::experimental::latch - std::experimental::latch
Synopsis
Defined in header <experimental/latch>
class latch; (concurrency TS)
The latch class is a downward counter of type ptrdiff_t which can be used to synchronize threads. The value of the counter is initialized on creation. Threads may block on the latch until the counter is decremented to zero. There is no possibility to increase or reset the counter, which makes the latch a single-use barrier.
Unlike std::experimental::barrier, std::experimental::latch can be decremented by a participating thread more than once.
Member functions
constructor (public member function)
destructor (public member function)
operator= not copy-assignable
[deleted]
count_down_and_wait (public member function)
count_down (public member function)
is_ready (public member function)
wait (public member function)