![]() |
Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members
|
#include <FXThread.h>
Public Member Functions | |
| FXSemaphore (FXint initial=1) | |
| void | wait () |
| FXbool | trywait () |
| void | post () |
| ~FXSemaphore () | |
A semaphore allows for protection of a resource that can be accessed by a fixed number of simultaneous threads.
| FX::FXSemaphore::FXSemaphore | ( | FXint | initial = 1 | ) |
Initialize semaphore with given count.
| FX::FXSemaphore::~FXSemaphore | ( | ) |
Delete semaphore.
| void FX::FXSemaphore::wait | ( | ) |
Decrement semaphore.
| FXbool FX::FXSemaphore::trywait | ( | ) |
Non-blocking semaphore decrement; return true if locked.
| void FX::FXSemaphore::post | ( | ) |
Increment semaphore.
|
|