Mutex Class Reference
A simple implementation of mutex as a wrapper around a pthread mutex or a win32 critical section.
More...
#include <mutex.h>
List of all members.
Detailed Description
A simple implementation of mutex as a wrapper around a pthread mutex or a win32 critical section.
If you locked a mutex you MUST unlock it within the same thread.
- Author:
- Jakob Schroeter <js@camaya.net>
- Since:
- 0.9
Definition at line 33 of file mutex.h.
Constructor & Destructor Documentation
Contructs a new simple mutex.
Definition at line 103 of file mutex.cpp.
Member Function Documentation
Tries to lock the mutex.
- Returns:
- True if the attempt was successful, false otherwise.
- Note:
- This function also returns true if mutex support is not available, ie. if gloox is compiled without pthreads on non-Windows platforms. Make sure threads/mutexes are available if your code relies on trylock().
Definition at line 118 of file mutex.cpp.
Releases the mutex.
Definition at line 123 of file mutex.cpp.
The documentation for this class was generated from the following files: