blocxx
BLOCXX_NAMESPACE::MutexLock Class Reference

#include <MutexLock.hpp>

Public Member Functions

 MutexLock (Mutex &mutex, bool initially_locked=true)
 
 ~MutexLock ()
 
void lock ()
 
void release ()
 
 MutexLock (const MutexLock &arg)
 
bool isLocked () const
 

Private Attributes

Mutexm_mutex
 
bool m_locked
 

Friends

class Condition
 

Detailed Description

Definition at line 49 of file MutexLock.hpp.

Constructor & Destructor Documentation

◆ MutexLock() [1/2]

BLOCXX_NAMESPACE::MutexLock::MutexLock ( Mutex & mutex,
bool initially_locked = true )
inlineexplicit

Definition at line 52 of file MutexLock.hpp.

References lock(), m_locked, and m_mutex.

Referenced by MutexLock().

◆ ~MutexLock()

BLOCXX_NAMESPACE::MutexLock::~MutexLock ( )
inline

Definition at line 60 of file MutexLock.hpp.

References m_locked, and release().

◆ MutexLock() [2/2]

BLOCXX_NAMESPACE::MutexLock::MutexLock ( const MutexLock & arg)
inline

Definition at line 86 of file MutexLock.hpp.

References m_locked, m_mutex, and MutexLock().

Member Function Documentation

◆ isLocked()

bool BLOCXX_NAMESPACE::MutexLock::isLocked ( ) const
inline

Definition at line 91 of file MutexLock.hpp.

References m_locked.

◆ lock()

void BLOCXX_NAMESPACE::MutexLock::lock ( )
inline

Definition at line 74 of file MutexLock.hpp.

References m_locked, and m_mutex.

Referenced by MutexLock().

◆ release()

void BLOCXX_NAMESPACE::MutexLock::release ( )
inline

Definition at line 80 of file MutexLock.hpp.

References m_locked, and m_mutex.

Referenced by ~MutexLock().

Friends And Related Symbol Documentation

◆ Condition

friend class Condition
friend

Definition at line 98 of file MutexLock.hpp.

References Condition.

Referenced by Condition.

Member Data Documentation

◆ m_locked

bool BLOCXX_NAMESPACE::MutexLock::m_locked
mutableprivate

Definition at line 97 of file MutexLock.hpp.

Referenced by isLocked(), lock(), MutexLock(), MutexLock(), release(), and ~MutexLock().

◆ m_mutex

Mutex* BLOCXX_NAMESPACE::MutexLock::m_mutex
private

Definition at line 96 of file MutexLock.hpp.

Referenced by lock(), MutexLock(), MutexLock(), and release().


The documentation for this class was generated from the following file: