Threads::ConditionVariable Class Reference

List of all members.

Public Member Functions

void signal ()
void broadcast ()
void wait (Mutex &mutex)

Private Attributes

std_cxx1x::condition_variable condition_variable

Detailed Description

Class implementing a condition variable. The semantics of this class and its member functions are the same as those of the POSIX functions.

Author:
Wolfgang Bangerth, 2003

Member Function Documentation

void Threads::ConditionVariable::signal (  )  [inline]

Signal to a single listener that a condition has been met, i.e. that some data will now be available.

References condition_variable.

void Threads::ConditionVariable::broadcast (  )  [inline]

Signal to multiple listener that a condition has been met, i.e. that some data will now be available.

References condition_variable.

void Threads::ConditionVariable::wait ( Mutex mutex  )  [inline]

Wait for the condition to be signalled. Signal variables need to be guarded by a mutex which needs to be given to this function as an argument, see the man page of posix_cond_wait for a description of the mechanisms.

The mutex is assumed held at the entry to this function but is released upon exit.

References condition_variable, and Threads::Mutex::mutex.


Member Data Documentation

std_cxx1x::condition_variable Threads::ConditionVariable::condition_variable [private]

Data object storing the necessary data.

Referenced by broadcast(), signal(), and wait().


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

deal.II documentation generated on Mon Nov 23 22:58:34 2009 by doxygen 1.6.1