lock overloads
Declared in <folly/Synchronized.h>
Make an exclusive locking helper.
template<
typename D,
typename M,
typename... Args>
auto
lock(
Synchronized<D, M>& synchronized,
Args&&... args);
» more...
Make an exclusive locking helper for a const object.
template<
typename D,
typename M,
typename... Args>
auto
lock(
Synchronized<D, M> const& synchronized,
Args&&... args);
» more...
Acquire locks on many lockables or synchronized instances in such a way that the sequence of calls within the function does not cause deadlocks.
template<
typename LockableOne,
typename LockableTwo,
typename... Lockables>
void
lock(
LockableOne& one,
LockableTwo& two,
Lockables&... lockables);
» more...
A locking helper for use with lock() or synchronized().
| Name | Description |
|---|---|
| synchronized | The object to lock. |
| args | Extra arguments forwarded to the locking function. |
| one | The first lockable to acquire. |
| two | The second lockable to acquire. |
| lockables | Any additional lockables to acquire. |