![]() |
Thread++
Client-Server Multithreading with C++
|
Thread manager. More...
#include <ThreadManager.h>
Public Member Functions | |
| CThreadManager () | |
| Constructor. More... | |
Protected Member Functions | |
| void | ProcessTask (CTask *) |
| Process the result of a task. More... | |
The thread manager takes care of the health and feeding of the threads. It is derived from CBaseThreadManager<CTask>. It has a function CThreadManager::ProcessTask() which overrides the virtual function CBaseThreadManager::ProcessTask() in order to process the results stored in the completed task descriptor.
| CThreadManager::CThreadManager | ( | ) |
Default constructor. All this does is call the CBaseThreadManager default constructor. If you have any initialization code, then it should go here.
|
protected |
Overrides the virtual function CBaseThreadManager::ProcessTask() in order to process the results stored in the completed task descriptor. In this case it means printing to the console a list of a task identifiers and the thread identifier of the thread that completed each task. Your task processing code should go here instead.
| pTask | Pointer to a task descriptor. |