Constructors

Synopses

Declared in <absl/synchronization/mutex.h>

Deleted copy constructor.

WriterMutexLock(WriterMutexLock const& other) = delete;

Deleted move constructor.

WriterMutexLock(WriterMutexLock&& other) = delete;

Acquires a write lock on mu for the lifetime of this object.

explicit
WriterMutexLock(Mutex& mu);

Deprecated pointer overload; acquires a write lock on *mu.

[[deprecated("Use the constructor that takes a reference instead")]]
explicit
WriterMutexLock(Mutex* mu);

Acquires a write lock on mu once cond holds.

explicit
WriterMutexLock(
    Mutex& mu,
    Condition const& cond);

Deprecated pointer overload; acquires a write lock on *mu once cond holds.

[[deprecated("Use the constructor that takes a reference instead")]]
explicit
WriterMutexLock(
    Mutex* mu,
    Condition const& cond);

Parameters

Name

Description

mu

The mutex to lock.

cond

The condition to wait for before locking.

Created with MrDocs