semaphore Class Reference
class supports semaphores
More...
#include <primitives.h>
List of all members.
|
Public Types |
| typedef HANDLE | _HANDLE_ |
Public Member Functions |
| | semaphore (size_t initial_count=1, size_t max_count=1) |
| | constructor
|
| | ~semaphore () |
| | destructor
|
| bool | release (size_t count=1) const |
| | releases semaphore NB!!! can be used in the const member function
|
| size_t | wait (size_t timeout=INFINITE) const |
| | waitd for signal state NB!!! can be used in the const member function
|
Private Member Functions |
| | semaphore (const semaphore &x) |
| | copy constructor
|
| semaphore & | operator= (const semaphore &x) |
| | assign operator
|
Private Attributes |
| HANDLE | _handle |
| | keep semaphore handle
|
Detailed Description
class supports semaphores
Definition at line 205 of file primitives.h.
Member Typedef Documentation
Constructor & Destructor Documentation
| semaphore::semaphore |
( |
const semaphore & |
x |
) |
[private] |
copy constructor
prevents the copying of objects
| semaphore::semaphore |
( |
size_t |
initial_count = 1, |
|
|
size_t |
max_count = 1 | |
|
) |
| | |
constructor
- Parameters:
-
| initial_count |
initial locks |
| max_count |
max locks |
Definition at line 231 of file primitives.cpp.
References _handle.
| semaphore::~semaphore |
( |
|
) |
|
Member Function Documentation
| bool semaphore::release |
( |
size_t |
count = 1 |
) |
const |
| size_t semaphore::wait |
( |
size_t |
timeout = INFINITE |
) |
const |
Member Data Documentation
The documentation for this class was generated from the following files: