Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

TGo4LockGuard Class Reference

#include <TGo4LockGuard.h>

List of all members.

Public Member Functions

 TGo4LockGuard (TMutex *mutex=0)
virtual ~TGo4LockGuard ()

Static Public Member Functions

static void LockMainMutex ()
static void UnLockMainMutex ()

Private Attributes

TMutex * fxMutex
 Reference to Mutex associated with this lockguard (external or internal).
Bool_t fbIsLocked
 We need this flag if first TThread starts in between ctor and dtor.
Bool_t fbIsMainMutex
 True if the mutex of this lockguard instance is the global go4 main mutex.

Static Private Attributes

static TMutex * fgxMainMutex = 0
 Main Mutex of the go4 system.
static Int_t fgiLockCount = 0
 Counts the numbers of locks of the recursive main mutex.


Constructor & Destructor Documentation

TGo4LockGuard::TGo4LockGuard TMutex *  mutex = 0  ) 
 

Definition at line 26 of file TGo4LockGuard.cxx.

References fbIsLocked, fbIsMainMutex, fgiLockCount, fgxMainMutex, and fxMutex.

TGo4LockGuard::~TGo4LockGuard  )  [virtual]
 

Definition at line 73 of file TGo4LockGuard.cxx.

References fbIsLocked, fbIsMainMutex, fgiLockCount, and fxMutex.


Member Function Documentation

void TGo4LockGuard::LockMainMutex  )  [static]
 

Definition at line 102 of file TGo4LockGuard.cxx.

References fgxMainMutex.

Referenced by TGo4Task::LockAll(), TGo4ServerTask::LockAll(), and TGo4Socket::Send().

void TGo4LockGuard::UnLockMainMutex  )  [static]
 

Definition at line 107 of file TGo4LockGuard.cxx.

References fgxMainMutex.

Referenced by TGo4Socket::Send(), TGo4Task::UnLockAll(), and TGo4ServerTask::UnLockAll().


Member Data Documentation

TMutex* TGo4LockGuard::fxMutex [private]
 

Reference to Mutex associated with this lockguard (external or internal).

Definition at line 57 of file TGo4LockGuard.h.

Referenced by TGo4LockGuard(), and ~TGo4LockGuard().

Bool_t TGo4LockGuard::fbIsLocked [private]
 

We need this flag if first TThread starts in between ctor and dtor.

Definition at line 60 of file TGo4LockGuard.h.

Referenced by TGo4LockGuard(), and ~TGo4LockGuard().

Bool_t TGo4LockGuard::fbIsMainMutex [private]
 

True if the mutex of this lockguard instance is the global go4 main mutex.

Definition at line 64 of file TGo4LockGuard.h.

Referenced by TGo4LockGuard(), and ~TGo4LockGuard().

TMutex * TGo4LockGuard::fgxMainMutex = 0 [static, private]
 

Main Mutex of the go4 system.

Used to protect any memory critical operations. This mutex is applied if lockguard is called without giving external mutex.

Definition at line 21 of file TGo4LockGuard.cxx.

Referenced by LockMainMutex(), TGo4LockGuard(), and UnLockMainMutex().

Int_t TGo4LockGuard::fgiLockCount = 0 [static, private]
 

Counts the numbers of locks of the recursive main mutex.

Definition at line 23 of file TGo4LockGuard.cxx.

Referenced by TGo4LockGuard(), and ~TGo4LockGuard().


The documentation for this class was generated from the following files:
Generated on Fri Nov 28 13:01:04 2008 for Go4-v3.04-1 by  doxygen 1.4.2