This class provides a simple thread implementation Actually is supported only POSIX THREAD.
More...
#include <vdkthread.h>
|
VDKThreadEnum | Start (void *=NULL) |
|
VDKThreadEnum | Stop () |
|
void * | Wait () |
|
unsigned int | GetID () |
|
|
void | Exit (void *status=0) |
|
This class provides a simple thread implementation Actually is supported only POSIX THREAD.
It is possible to use a VDKThread in two way:
- via subclassing: if you derive a new class from VDKThread, you have to override the
- virtual method "virtual void Execute ();" to do what you want
protected:
void Execute () {
}
public:
NewClass ();
~NewsClass ();
}
NewClass thread;
thread.Start();
This class provides a simple thread implementation Actually is supported only POSIX THREAD.
Definition: vdkthread.h:92
- passing a pointer to function when calling "Start ( (void *) func);"
void * func () {}
...
VDKThread thread;
thread.Start ((void *) func);
◆ Exit()
void VDKThread::Exit |
( |
void * |
status = 0 | ) |
|
|
protected |
◆ GetID()
unsigned int VDKThread::GetID |
( |
| ) |
|
|
inline |
◆ Start()
VDKThreadEnum VDKThread::Start |
( |
void * |
arg = NULL | ) |
|
◆ Stop()
VDKThreadEnum VDKThread::Stop |
( |
| ) |
|
Stops executing thread (command from other threads).
◆ Wait()
void * VDKThread::Wait |
( |
| ) |
|
Wait until the thread is terminated (it is used from other threads).
◆ state
VDKThreadEnum VDKThread::state |
The documentation for this class was generated from the following files: