process_mutex Class Reference

#include <platformstl/synch/process_mutex.hpp>

List of all members.


Detailed Description

A process mutex class.

The class is not actually defined in the platformstl namespace. Rather, it resolves to the appropriate type for the given platform, relying on Intersecting Conformance of the resolved platform-specific types.

When compiling on UNIX platforms, the platformstl::process_mutex type resolves to the unixstl::process_mutex class. On Windows platforms it resolves to the winstl::process_mutex class. It is not defined for other platforms.

Public Types

Member Types
typedef process_mutex class_type
typedef handle_type resource_type

Public Member Functions

Construction
 process_mutex ()
 Constructs a mutex object.
 ~process_mutex ()
 Destroys a mutex object.
Operations
void lock ()
 Acquires a lock on the mutex, pending the thread until the lock is aquired.
bool try_lock ()
 Attempts to lock the mutex.
void unlock ()
 Releases an aquired lock on the mutex.
Accessors
handle_type get ()
 The underlying kernel object handle.


Constructor & Destructor Documentation

process_mutex (  ) 

Constructs a mutex object.

~process_mutex (  ) 

Destroys a mutex object.


Member Function Documentation

void lock (  ) 

Acquires a lock on the mutex, pending the thread until the lock is aquired.

bool try_lock (  ) 

Attempts to lock the mutex.

Returns:
true if the mutex was aquired, or false if not

void unlock (  ) 

Releases an aquired lock on the mutex.

handle_type get (  ) 

The underlying kernel object handle.


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

Generated on Thu Jun 10 08:58:33 2010 for STLSoft by  doxygen 1.5.6