Class for managing multi-threaded procedures. More...
#include <spThreadManager.hpp>
Public Member Functions | |
ThreadManager (PFNTHREADPROC ThreadProc, void *Arguments=0, bool StartImmediately=true) | |
~ThreadManager () | |
bool | running () const |
Returns true if the thread is currently running and returns false if the thread was already terminated. | |
void | pause () |
Pauses (or rather suspends) the thread. | |
void | resume () |
Resumes the paused thread. | |
void | terminate () |
Terminates the thread execution. | |
void | setPriority (const EThreadPriorityClasses PriorityClass) |
Sets the thread priority. By default THREADPRIORITY_NORMAL. |
Class for managing multi-threaded procedures.
sp::ThreadManager::ThreadManager | ( | PFNTHREADPROC | ThreadProc, | |
void * | Arguments = 0 , |
|||
bool | StartImmediately = true | |||
) |
sp::ThreadManager::~ThreadManager | ( | ) |
void sp::ThreadManager::pause | ( | ) |
Pauses (or rather suspends) the thread.
void sp::ThreadManager::resume | ( | ) |
Resumes the paused thread.
bool sp::ThreadManager::running | ( | ) | const |
Returns true if the thread is currently running and returns false if the thread was already terminated.
void sp::ThreadManager::setPriority | ( | const EThreadPriorityClasses | PriorityClass | ) |
Sets the thread priority. By default THREADPRIORITY_NORMAL.
void sp::ThreadManager::terminate | ( | ) |
Terminates the thread execution.