Argus Camera Sample Argus Camera Sample

- Main Page
- Related Pages
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Private Member Functions | Private Attributes
ArgusSamples::ConditionVariable Class Reference

Conditional. More...

`#include <ConditionVariable.h>`

List of all members.

## Public Member Functions

| ConditionVariable ()
| ~ConditionVariable ()
bool | initialize ()
| Create the underlying condition variable.
bool | shutdown ()
| Destroy the underlying condition variable.
bool | broadcast () const
| Broadcast the condition variable.
bool | signal () const
| Signal the condition variable.
bool | wait (const Mutex &mutex) const
| Wait on the condition variable.

## Private Member Functions

| ConditionVariable (ConditionVariable &other)
| Hide copy constructor and assignment operator.
const ConditionVariable & | operator= (const ConditionVariable &)

## Private Attributes

bool | m_initialized
pthread_cond_t | m_cond
| pthread conditional variable, this is 'mutable' so that 'const' functions can be used.

## Detailed Description

Conditional.

Definition at line 42 of file ConditionVariable.h.

## Constructor & Destructor Documentation

ArgusSamples::ConditionVariable::ConditionVariable | ( |  | ) |

Definition at line 35 of file ConditionVariable.cpp.

ArgusSamples::ConditionVariable::~ConditionVariable | ( |  | ) |

Definition at line 40 of file ConditionVariable.cpp.

ArgusSamples::ConditionVariable::ConditionVariable | ( | ConditionVariable & | other | ) |

private

Hide copy constructor and assignment operator.

## Member Function Documentation

bool ArgusSamples::ConditionVariable::broadcast | ( |  | ) | const

Broadcast the condition variable.

This method is declared `const` for convenience.

Definition at line 69 of file ConditionVariable.cpp.

bool ArgusSamples::ConditionVariable::initialize | ( |  | ) |

Create the underlying condition variable.

This method must be called before any other methods.

Definition at line 45 of file ConditionVariable.cpp.

const ConditionVariable& ArgusSamples::ConditionVariable::operator= | ( | const ConditionVariable & |  | ) |

private

bool ArgusSamples::ConditionVariable::shutdown | ( |  | ) |

Destroy the underlying condition variable.

After this call, this object can no longer be used (until and unless a future call to `initialize()`). Calling this method if the object is not initialized generates no error, but silently returns.

Definition at line 57 of file ConditionVariable.cpp.

bool ArgusSamples::ConditionVariable::signal | ( |  | ) | const

Signal the condition variable.

This method is declared `const` for convenience.

Definition at line 79 of file ConditionVariable.cpp.

bool ArgusSamples::ConditionVariable::wait | ( | const Mutex & | mutex | ) | const

Wait on the condition variable.

This method is declared `const` for convenience.

Parameters:

  [in] | mutex | The mutex that will be released while waiting. When multiple threads are waiting concurrently, they must all be using the same mutex.

Definition at line 89 of file ConditionVariable.cpp.

## Member Data Documentation

pthread_cond_t ArgusSamples::ConditionVariable::m_cond

mutableprivate

pthread conditional variable, this is 'mutable' so that 'const' functions can be used.

Definition at line 83 of file ConditionVariable.h.

bool ArgusSamples::ConditionVariable::m_initialized

private

Definition at line 79 of file ConditionVariable.h.

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

- common/ConditionVariable.h
- common/ConditionVariable.cpp