gml_GlobalMutex.h File Reference


Detailed Description

Wrapper around APR's cross-process mutexes.

#include "gml/base/gml_Types.h"
#include "gml/base/gml_Errors.h"

Go to the source code of this file.


Typedefs

typedef gml_TGlobalMutex_ * gml_TGlobalMutex
 Opaque type for cross-process mutexes.

Functions

GML_EXTERN_C gml_TError gml_GlobalMutex_Open (gml_TGlobalMutex *mutex, UInt32 *name)
 Create a cross process mutex identified system-wide by name.
GML_EXTERN_C void gml_GlobalMutex_Lock (gml_TGlobalMutex mutex)
 Acquire an exclusive lock on a mutex.
GML_EXTERN_C void gml_GlobalMutex_Unlock (gml_TGlobalMutex mutex)
 Release a locked mutex.
GML_EXTERN_C void gml_GlobalMutex_Close (gml_TGlobalMutex *mutex)
 Release any resources claimed by a mutex.

Function Documentation

GML_EXTERN_C gml_TError gml_GlobalMutex_Open ( gml_TGlobalMutex mutex,
UInt32 name 
)

Create a cross process mutex identified system-wide by name.

If no name is provided, one will be generated and returned.

GML_EXTERN_C void gml_GlobalMutex_Lock ( gml_TGlobalMutex  mutex  ) 

Acquire an exclusive lock on a mutex.

The result of locking a mutex twice from the same thread is undefined.

GML_EXTERN_C void gml_GlobalMutex_Unlock ( gml_TGlobalMutex  mutex  ) 

Release a locked mutex.

It is not an error to unlock a mutex multiple times. Behavior is undefined is the mutex has never been locked before.

Generated on Tue Jun 12 14:03:28 2007 for gml by Doxygen 1.5.2.