The TimedLockable requirements describe the characteristics of types that provide timed exclusive blocking semantics for execution agents (threads, processes, tasks).
For type L to be TimedLockable, given.
rel_time, a value of a specialization of std::chrono::duration, and abs_time, a value of a specialization of std::chrono::time_point, the following conditions have to be satisfied for an object m of type L:
| Expression | Effects | Return value | 
|---|---|---|
| m.try_lock_for(rel_time) | Blocks for the provided duration rel_timeor until a lock onmis acquired. | trueif the lock was acquired,falseotherwise. | 
| m.try_lock_until(abs_time) | Blocks until the provided time point abs_timeis reached or a lock onmis acquired. | trueif the lock was acquired,falseotherwise. | 
The try_lock_for and try_lock_until member functions obtain a non-shared lock on m on succcess.
    © cppreference.com
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.
    https://en.cppreference.com/w/cpp/named_req/TimedLockable