36template <
class Mutex,
class CondVar>
bool tryWait()
Perform a non-blocking wait.
std::condition_variable cond_
BasicSemaphore(size_type count=0)
Create the semaphore, with an optional initial count.
void notify()
Increment the count and unblock one waiting thread.
void wait()
Block until notify is called.
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
BasicSemaphore< std::mutex, std::condition_variable > semaphore