Logo Search packages:      
Sourcecode: ardour version File versions  Download package

Glib::Mutex Class Reference
[Threads]

#include <thread.h>

List of all members.


Detailed Description

Represents a mutex (mutual exclusion). It can be used to protect data against shared access. Try to use Mutex::Lock instead of calling lock() and unlock() directly -- it will make your life much easier.

Note:
Before creating a Glib::Mutex, Glib::thread_init() has to be called.

Glib::Mutex is not recursive, i.e. a thread will deadlock, if it already has locked the mutex while calling lock(). Use Glib::RecMutex instead, if you need recursive mutexes.

Definition at line 373 of file thread.h.


Public Member Functions

GMutex * gobj ()
void lock ()
bool trylock ()
void unlock ()

Private Member Functions

 Mutex (const Mutex &)
Mutexoperator= (const Mutex &)

Private Attributes

GMutex * gobject_

Classes

class  Lock

The documentation for this class was generated from the following files:

Generated by  Doxygen 1.6.0   Back to index