15 #ifndef REMUTEXDIRECT_H
16 #define REMUTEXDIRECT_H
18 #include "pandabase.h"
19 #include "mutexTrueImpl.h"
20 #include "conditionVarImpl.h"
35 INLINE ~ReMutexDirect();
37 INLINE ReMutexDirect(
const ReMutexDirect ©);
38 INLINE
void operator = (
const ReMutexDirect ©);
41 BLOCKING INLINE
void acquire()
const;
42 BLOCKING INLINE
void acquire(
Thread *current_thread)
const;
43 BLOCKING INLINE
bool try_acquire()
const;
44 BLOCKING INLINE
bool try_acquire(
Thread *current_thread)
const;
45 INLINE
void elevate_lock()
const;
46 INLINE
void release()
const;
48 INLINE
bool debug_is_locked()
const;
50 INLINE
void set_name(
const string &name);
51 INLINE
void clear_name();
52 INLINE
bool has_name()
const;
53 INLINE
string get_name()
const;
55 void output(ostream &out)
const;
58 #ifdef HAVE_REMUTEXTRUEIMPL
63 INLINE
void do_acquire();
64 void do_acquire(
Thread *current_thread);
65 INLINE
bool do_try_acquire();
66 bool do_try_acquire(
Thread *current_thread);
67 void do_elevate_lock();
74 ConditionVarImpl _cvar_impl;
75 #endif // HAVE_REMUTEXTRUEIMPL
86 #include "reMutexDirect.I"
88 #endif // !DEBUG_THREADS
This class implements a standard lightReMutex by making direct calls to the underlying implementation...
This class implements a standard reMutex by making direct calls to the underlying implementation laye...
void output(ostream &out) const
This method is declared virtual in MutexDebug, but non-virtual in ReMutexDirect.
A thread; that is, a lightweight process.
A fake mutex implementation for single-threaded applications that don't need any synchronization cont...