Public Member Functions | Static Public Member Functions | List of all members

#include <tjthread.h>

Public Member Functions

 Thread ()
 
bool start (unsigned int stack_size=0)
 
bool wait ()
 
virtual void run ()=0
 

Static Public Member Functions

static int self ()
 

Detailed Description

Base class for threads. Derive from this and implement the run() function to use it.

Definition at line 163 of file tjthread.h.

Constructor & Destructor Documentation

§ Thread()

Thread::Thread ( )

Constructs thread object with the given label.

Member Function Documentation

§ run()

virtual void Thread::run ( )
pure virtual

Implement to run threads execution path.

§ self()

static int Thread::self ( )
static

Returns thread-unique ID of the current thread.

§ start()

bool Thread::start ( unsigned int  stack_size = 0)

Starts the thread. 'stack_size' is used as the threads stack size if not zero (in which case the systems default stack size is used). Returns 'true' only on sucess.

§ wait()

bool Thread::wait ( )

Waits for the thread to finish. Returns 'true' only on sucess.


The documentation for this class was generated from the following file: