mx::mxSem Class Reference
List of all members.
Detailed Description
Definition at line 31 of file mxsemaphore.h.
Constructor & Destructor Documentation
| mx::mxSem::mxSem |
( |
unsigned int |
value |
) |
[explicit] |
constructor
Definition at line 24 of file mxsemaphore.cpp.
00025 {
00026
00027 sem = SDL_CreateSemaphore(value);
00028
00029
00030 }
destructor
Definition at line 32 of file mxsemaphore.cpp.
00033 {
00034
00035 if(sem != 0)
00036 SDL_DestroySemaphore(sem);
00037
00038 }
Member Function Documentation
| const unsigned int mx::mxSem::currentValue |
( |
|
) |
const |
currentValue
Definition at line 40 of file mxsemaphore.cpp.
00041 {
00042
00043 return SDL_SemValue(sem);
00044
00045 }
post
Definition at line 68 of file mxsemaphore.cpp.
00069 {
00070 return SDL_SemPost(sem);
00071 }
| int mx::mxSem::tryWait |
( |
|
) |
|
tryWait
Definition at line 54 of file mxsemaphore.cpp.
00055 {
00056
00057 return SDL_SemTryWait(sem);
00058
00059 }
wait
Definition at line 47 of file mxsemaphore.cpp.
00048 {
00049
00050 return SDL_SemWait(sem);
00051
00052 }
| int mx::mxSem::waitTimeout |
( |
unsigned int |
interval |
) |
|
waitTimeout
Definition at line 61 of file mxsemaphore.cpp.
00062 {
00063
00064 return SDL_SemWaitTimeout(sem, interval);
00065
00066 }
The documentation for this class was generated from the following files: