00001 //--------------------------------------------------------------- 00002 // Go4 Release Package v2.10-5 (build 21005) 00003 // 03-Nov-2005 00004 //--------------------------------------------------------------- 00005 // The GSI Online Offline Object Oriented (Go4) Project 00006 // Experiment Data Processing at DVEE department, GSI 00007 //--------------------------------------------------------------- 00008 // 00009 //Copyright (C) 2000- Gesellschaft f. Schwerionenforschung, GSI 00010 // Planckstr. 1, 64291 Darmstadt, Germany 00011 //Contact: http://go4.gsi.de 00012 //---------------------------------------------------------------- 00013 //This software can be used under the license agreements as stated 00014 //in Go4License.txt file which is part of the distribution. 00015 //---------------------------------------------------------------- 00016 #ifndef TGo4LockGuard_h 00017 #define TGo4LockGuard_h 1 00018 00040 class TMutex; 00041 00042 #include "Rtypes.h" 00043 00044 class TGo4LockGuard { 00045 public: 00046 00047 TGo4LockGuard (TMutex* mutex=0); 00048 00049 virtual ~TGo4LockGuard(); 00050 00051 private: 00052 00056 TMutex *fxMutex; 00057 00061 Bool_t fbIsLocked; 00062 00066 Bool_t fbIsMainMutex; 00067 00068 public: 00069 00076 static TMutex* fgxMainMutex; 00077 00082 static Int_t fgiLockCount; 00083 00084 ClassDef(TGo4LockGuard,1) 00085 }; 00086 00087 #endif 00088 00089 //----------------------------END OF GO4 SOURCE FILE ---------------------