CThread Class 1.0 Reference Manual
Dominik Filipp, © 1999, Slovakia
2 CThread API Reference - 05/26/99
CThread Class........................................................................................4
CThreadException Class.......................................................................4
License Conditions.................................................................................4
Module CThread.cpp ............................................................................4
Module CThread.h ................................................................................5
CThread Class........................................................................................5
CThread::CloseProcessLocking..................................................................7
CThread::Continue ......................................................................................8
CThread::CThread ......................................................................................8
CThread::GetActivityStatus .......................................................................9
CThread::GetAttributes ..............................................................................9
CThread::GetExitCode..............................................................................10
CThread::GetHandle .................................................................................10
CThread::GetID .........................................................................................10
CThread::GetOwnerParams.....................................................................11
CThread::GetPriority ................................................................................11
CThread::GetStackSize .............................................................................12
CThread::IsAlive........................................................................................12
CThread::Kill .............................................................................................12
CThread::Lock ...........................................................................................13
CThread::OnKill ........................................................................................14
CThread::OpenProcessLocking................................................................14
CThread::Pause..........................................................................................15
CThread::ProcessLock ..............................................................................15
CThread::ProcessUnlock...........................................................................16
CThread::Reset ..........................................................................................16
CThread::ResetCommands.......................................................................17
CThread::Run ............................................................................................17
CThread::SendCommand .........................................................................18
CThread::SetActivityStatus ......................................................................19
CThread::SetAttributes.............................................................................20
CThread::SetOwnerParams......................................................................21
CThread::SetPriority.................................................................................21
CThread::SetStackSize ..............................................................................22
CThread API Reference - 05/26/99 3
CThread::Start ...........................................................................................22
CThread::Stop ............................................................................................23
CThread::ThreadHandler.........................................................................24
CThread::Unlock........................................................................................24
CThread::WaitForActivityStatus.............................................................24
CThread::WaitForNotification.................................................................25
CThread::~CThread ..................................................................................26
CThreadException Class.....................................................................26
CThreadException::CThreadException ..................................................27
CThreadException::CThreadException ..................................................28
CThreadException::CThreadException ..................................................29
CThreadException::GetErrorMsg ...........................................................29
CThreadException::GetExceptionType...................................................30
CThreadException::GetLastSystemErrorMsg .......................................30
CThreadException::GetThread................................................................31
CThreadException::ReportError.............................................................31
CThreadException::SetErrorMsg ............................................................31
CThreadException::SetErrorMsg ............................................................32
CThreadException::SetExceptionType....................................................32
CThreadException::SetThread.................................................................33
CThread Activity Status Predefined Values .....................................33
CThread General Predefined Values.................................................34
CThread Predefined Commands........................................................34
CThreadException Predefined Types................................................35
4 CThread API Reference - 05/26/99
CThread Class
The base MFC CObject-derived class that encapsulates WINDOWS Worker
Thread abilities.
CThread class offers many features that are not implemented or supported by
WINDOWS System. It allows to build up the full-fledged OOP Class hierarchy,
supports several levels of safe Thread Synchronization as well as the Thread
Notification.
Detailed information how do CThreads work, how should be managed or handled
can be found in the 'Developer.doc' documentation in '\Doc' subdirectory of the
main installation directory.
CThreadException Class
The base CException-derived class used in CThread-derived classes.
License Conditions
This software is a freeware and may be freely used or distributed without
restriction.
Module CThread.cpp
PROJECT : CThread Class
SUBSYSTEM : CThread Base Class
AUTHOR : Dominik Filipp, © 1999, Slovakia, Europe
DESCRIPTION:
Abstract Base CThread Class implementation file.
Module CThread.h
PROJECT : CThread Class
SUBSYSTEM : CThread Base Class
AUTHOR : Dominik Filipp, © 1999, Slovakia, Europe
Description
Description
CThread API Reference - 05/26/99 5
DESCRIPTION:
Abstract Base CThread Class header file.
CThread Class
class CThread: public CObject
CThread Class Members
Public Members:
CThread(void* pOwnerObject = NULL, LPARAM lParam = 0L)
CThread Constructor
virtual ~CThread()
CThread Destructor
SECURITY_ATTRIBUTES GetAttributes() const
Get Thread Attributes
DWORD GetStackSize() const
Get Thread Stack Size
HANDLE GetHandle() const
Get Thread Handle
DWORD GetID() const
Get Thread ID
DWORD GetExitCode() const
Get Thread Exit Code
int GetActivityStatus() const
Get Thread Activity Status
int GetPriority() const
Get WINDOWS Thread Priority
BOOL IsAlive()
Check if Thread is Alive
void Start()
Start Thread
void Run()
Fire Run Command
void Pause()
Fire Pause Command
Class Members