OpenThreads::BlockCount Class Reference

`#include <Block>`

Inheritance diagram for OpenThreads::BlockCount:

## Public Member Functions

| BlockCount (unsigned int blockCount)
| ~BlockCount ()
void | completed ()
void | block ()
void | reset ()
void | release ()
void | setBlockCount (unsigned int blockCount)
unsigned int | getBlockCount () const
unsigned int | getCurrentCount () const

## Protected Attributes

OpenThreads::Mutex | _mut
OpenThreads::Condition | _cond
unsigned int | _blockCount
unsigned int | _currentCount

## Detailed Description

BlockCount is a block that can be used to halt a thread that is waiting for a specified number of operations to be completed.

## Constructor & Destructor Documentation

## BlockCount()

OpenThreads::BlockCount::BlockCount | ( | unsigned int | blockCount | ) |

inline

References _blockCount, and _currentCount.

Referenced by osg::RefBlockCount::RefBlockCount().

## ~BlockCount()

OpenThreads::BlockCount::~BlockCount | ( |  | ) |

inline

References _blockCount, and release().

## Member Function Documentation

## block()

void OpenThreads::BlockCount::block | ( |  | ) |

inline

References _cond, _currentCount, and _mut.

## completed()

void OpenThreads::BlockCount::completed | ( |  | ) |

inline

References _cond, _currentCount, and _mut.

## getBlockCount()

unsigned int OpenThreads::BlockCount::getBlockCount | ( |  | ) | const

inline

References _blockCount.

## getCurrentCount()

unsigned int OpenThreads::BlockCount::getCurrentCount | ( |  | ) | const

inline

References _currentCount.

## release()

void OpenThreads::BlockCount::release | ( |  | ) |

inline

References _cond, _currentCount, and _mut.

Referenced by ~BlockCount().

## reset()

void OpenThreads::BlockCount::reset | ( |  | ) |

inline

References _blockCount, _cond, _currentCount, and _mut.

## setBlockCount()

void OpenThreads::BlockCount::setBlockCount | ( | unsigned int | blockCount | ) |

inline

References _blockCount.

## Member Data Documentation

## _blockCount

unsigned int OpenThreads::BlockCount::_blockCount

protected

Referenced by BlockCount(), getBlockCount(), reset(), setBlockCount(), and ~BlockCount().

## _cond

OpenThreads::Condition OpenThreads::BlockCount::_cond

protected

Referenced by block(), completed(), release(), and reset().

## _currentCount

unsigned int OpenThreads::BlockCount::_currentCount

protected

Referenced by block(), BlockCount(), completed(), getCurrentCount(), release(), and reset().

## _mut

OpenThreads::Mutex OpenThreads::BlockCount::_mut

protected

Referenced by block(), completed(), release(), and reset().

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

- Block