
Public Member Functions | |
| Semaphore (int v=1) | |
| ~Semaphore () | |
| void | p () |
| void | v () |
| void | freeResources () |
Static Public Member Functions | |
| static int | init (System_Info *si) |
Private Attributes | |
| volatile int | _value |
Static Private Attributes | |
| static const Type_Id | TYPE = Type<Semaphore>::TYPE |
Definition at line 20 of file semaphore.h.
| Semaphore::Semaphore | ( | int | v = 1 |
) | [inline] |
| Semaphore::~Semaphore | ( | ) | [inline] |
Destructor. Frees all Threads that were waiting on the Semaphore instance
Definition at line 33 of file semaphore.h.
| void Semaphore::freeResources | ( | ) | [inline] |
Frees all resources locked by this Semaphore
Definition at line 60 of file semaphore.h.
| __BEGIN_SYS int Semaphore::init | ( | System_Info * | si | ) | [static] |
System init call (Object system constructor)
Definition at line 12 of file semaphore_init.cc.
| void Semaphore::p | ( | ) | [inline] |
Locks one semaphore resource. If no resources are currently available then waits until one become available
Definition at line 42 of file semaphore.h.
| void Semaphore::v | ( | ) | [inline] |
Unlocks one semaphore resource. Wakes one locked Thread
Definition at line 51 of file semaphore.h.
volatile int Semaphore::_value [private] |
Current value of the Semaphore counter
Definition at line 74 of file semaphore.h.
const Type_Id Semaphore::TYPE = Type<Semaphore>::TYPE [static, private] |
Internal Semaphore Type_Id
Definition at line 72 of file semaphore.h.
1.5.8