16 template<
class Lockable>
17 void wait(Lockable& lock) {
wait(lock, MonoClock::TimePoint::max()); }
18 template<
class Lockable,
class Rep,
class Period>
20 template<
class Lockable,
class Clock,
class Dur>
28 return _cond.
wait(
internal, time);
A scoped lock that references any lockable. Locks on construction and unlocks on destruction.
Definition: Mutex.h:10
Method to synchronize threads. Condition variables eliminate the need for repeated polling to check t...
Definition: Condition.h:18
TimePoint represented by a duration since a clock's epoch time.
Definition: TimePoint.h:11
static TimePoint now()
Get current time.
Definition: Clock.h:48
Condition that can be used with any kind of lock. Slightly slower than the default Condition class...
Definition: Any.h:10
static auto _
Definition: Module.cpp:8
bool wait(Lockable &lock, Duration< Rep, Period > time)
Definition: Any.h:19
void signal()
Definition: Any.h:13
void broadcast()
Signal all waiting threads to resume, all resumed threads attempt to acquire the lock.
Definition: Condition.h:25
function< void()> lockGuard(Lock &lock)
Definition: Unique.h:27
void unlock()
Definition: Unique.h:103
static constexpr Duration max()
Maximum duration (positive reps)
Definition: Duration.h:86
Duration represented by repetitions of a period. The period must be a ratio.
Definition: Duration.h:7
void wait(UniqueLock< Mutex > &lock)
Release lock and wait until thread is signaled.
Definition: Condition.h:28
bool wait(Lockable &external, TimePoint< Clock, Dur > time)
Definition: Any.h:21
A thread lock where the lock is acquired by suspending thread execution until it becomes available...
Definition: Mutex.h:17
void signal()
Signal one waiting thread to resume, resumed thread attempts to acquire the lock. ...
Definition: Condition.h:23
void wait(Lockable &lock)
Definition: Any.h:17
Global Honeycomb namespace.
void broadcast()
Definition: Any.h:14