Reference documentation for deal.II version Git 350fd17bfc 2020-02-26 19:16:00 +0100
\(\newcommand{\vcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\vcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Public Member Functions | Private Attributes | List of all members
Threads::ConditionVariable Class Reference

#include <deal.II/base/thread_management.h>

Public Member Functions

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

Private Attributes

std::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.

Deprecated:
Use std::condition_variable instead.
Author
Wolfgang Bangerth, 2003

Definition at line 175 of file thread_management.h.

Member Function Documentation

◆ signal()

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.

Definition at line 183 of file thread_management.h.

◆ broadcast()

void Threads::ConditionVariable::broadcast ( )
inline

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

Definition at line 193 of file thread_management.h.

◆ wait()

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 pthread_cond_wait for a description of the mechanisms.

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

Definition at line 208 of file thread_management.h.

Member Data Documentation

◆ condition_variable

std::condition_variable Threads::ConditionVariable::condition_variable
private

Data object storing the necessary data.

Definition at line 218 of file thread_management.h.


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