TC::MT::ClassLevelLockable< CLASS_TO_LOCK > Class Template Reference
[Multithreading]

This template offers the basic mechanism for an class level locking mechanism. More...

#include <TCMTLockable.h>

Inheritance diagram for TC::MT::ClassLevelLockable< CLASS_TO_LOCK >:

Inheritance graph
[legend]
Collaboration diagram for TC::MT::ClassLevelLockable< CLASS_TO_LOCK >:

Collaboration graph
[legend]

List of all members.

Classes

class  Locker
 Helper class for locking the whole class This nested class is used for locking and unlocking the given object by the use of the constructor/destructor of the object. More...

Public Member Functions

bool Lock ()
 Lock the class.
bool UnLock ()
 UnLock the class.

Static Private Attributes

static MutexPtr m_mutex = Factory::CreateMutex()

Friends

class Locker


Detailed Description

template<class CLASS_TO_LOCK>
class TC::MT::ClassLevelLockable< CLASS_TO_LOCK >

This template offers the basic mechanism for an class level locking mechanism.

Definition at line 97 of file TCMTLockable.h.


Member Function Documentation

template<class CLASS_TO_LOCK >
bool TC::MT::ClassLevelLockable< CLASS_TO_LOCK >::Lock (  )  [inline]

Lock the class.

Definition at line 119 of file TCMTLockable.h.

References TC::MT::ClassLevelLockable< CLASS_TO_LOCK >::m_mutex.

template<class CLASS_TO_LOCK >
bool TC::MT::ClassLevelLockable< CLASS_TO_LOCK >::UnLock (  )  [inline]

UnLock the class.

Definition at line 125 of file TCMTLockable.h.

References TC::MT::ClassLevelLockable< CLASS_TO_LOCK >::m_mutex.


Friends And Related Function Documentation

template<class CLASS_TO_LOCK >
friend class Locker [friend]

Definition at line 133 of file TCMTLockable.h.


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

Copyright (c) Thomas Goessler 2003 - 2008