Image Component Library (ICL)
Public Member Functions | Private Attributes | List of all members
icl::utils::Lockable Class Reference

Interface for objects, that can be locked using an internal mutex. More...

#include <Lockable.h>

Inheritance diagram for icl::utils::Lockable:
icl::geom::Scene icl::physics::PhysicsWorld icl::qt::AdjustGridMouseHandler icl::qt::DefineQuadrangleMouseHandler icl::qt::DefineRectanglesMouseHandler icl::qt::DragRectangleMouseHandler icl::utils::ConfigFile icl::physics::PhysicsScene icl::physics::PhysicsScene

Public Member Functions

 Lockable (bool recursive=false)
 Default constructor. More...
 
 Lockable (const Lockable &l)
 copy constructor (does not copy the source mutex) More...
 
Lockableoperator= (const Lockable &l)
 assignment operator (does not copy the source mutex) More...
 
 ~Lockable ()
 Destructor. More...
 
void lock () const
 lock object More...
 
void unlock () const
 unlock object More...
 
MutexgetMutex () const
 returns mutex of this object More...
 

Private Attributes

Mutexm_mutex
 wrapped mutex variable More...
 

Detailed Description

Interface for objects, that can be locked using an internal mutex.

Constructor & Destructor Documentation

icl::utils::Lockable::Lockable ( bool  recursive = false)
inline

Default constructor.

icl::utils::Lockable::Lockable ( const Lockable l)
inline

copy constructor (does not copy the source mutex)

icl::utils::Lockable::~Lockable ( )
inline

Destructor.

Member Function Documentation

Mutex& icl::utils::Lockable::getMutex ( ) const
inline

returns mutex of this object

void icl::utils::Lockable::lock ( ) const
inline

lock object

Lockable& icl::utils::Lockable::operator= ( const Lockable l)
inline

assignment operator (does not copy the source mutex)

void icl::utils::Lockable::unlock ( ) const
inline

unlock object

Member Data Documentation

Mutex* icl::utils::Lockable::m_mutex
private

wrapped mutex variable


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