6#if (defined(__OS_IRIX__) || defined(__OS_LINUX__) || defined(__OS_MACOSX__))
10 typedef pthread_t THREAD_HANDLE;
11 typedef void * THREAD_RETURN;
12 typedef void * (*THREAD_FUNCTION)(
void *);
14#elif defined(__OS_WINDOWS__)
18 #define THREAD_TYPE __stdcall
19 typedef unsigned long THREAD_HANDLE;
20 typedef unsigned THREAD_RETURN;
21 typedef unsigned (__stdcall *THREAD_FUNCTION)(
void *);
64 bool start( THREAD_FUNCTION routine,
void * ptr = NULL );
92 THREAD_HANDLE thread_;
STK base class.
Definition Stk.h:136
STK thread class.
Definition Thread.h:50
void testCancel(void)
Create a cancellation point within a thread routine.
Thread()
Default constructor.
bool cancel(void)
Signal cancellation of a thread routine, returning true on success.
bool start(THREAD_FUNCTION routine, void *ptr=NULL)
Begin execution of the thread routine. Upon success, true is returned.
bool wait(void)
Block the calling routine indefinitely until the thread terminates.
~Thread()
The class destructor does not attempt to cancel or join a thread.
The STK namespace.
Definition ADSR.h:6