|
Sleeping Wombat Common Library
0.50.0
swCommonLibrary
|
Can block multiple threads and wait for signal. ThreadsBarrier is reusable. More...
#include <ThreadsBarrier.h>
Public Member Functions | |
| ThreadsBarrier (uint16 numThreads) | |
| void | ArriveAndWait () |
Private Attributes | |
| std::mutex | m_lock |
| std::condition_variable | m_condVariable |
| Size | m_generation |
| const uint32 | m_numThreads |
| uint32 | m_remain |
Can block multiple threads and wait for signal. ThreadsBarrier is reusable.
Implementation based on http://stackoverflow.com/questions/24465533/implementing-boostbarrier-in-c11
1.8.9.1