00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef LIGHTMUTEXHOLDER_H
00016 #define LIGHTMUTEXHOLDER_H
00017
00018 #include "pandabase.h"
00019 #include "lightMutex.h"
00020
00021 class Thread;
00022
00023
00024
00025
00026
00027 class EXPCL_PANDA_PIPELINE LightMutexHolder {
00028 public:
00029 INLINE LightMutexHolder(const LightMutex &mutex);
00030 INLINE LightMutexHolder(LightMutex *&mutex);
00031 INLINE ~LightMutexHolder();
00032 private:
00033 INLINE LightMutexHolder(const LightMutexHolder ©);
00034 INLINE void operator = (const LightMutexHolder ©);
00035
00036 private:
00037 #if defined(HAVE_THREADS) || defined(DEBUG_THREADS)
00038 const LightMutex *_mutex;
00039 #endif
00040 };
00041
00042 #include "lightMutexHolder.I"
00043
00044 #endif