文件名称:test4
介绍说明--下载内容均来自于网络,请自行研究使用
大家知道在VC++中我们可以用CreateThread创建一个线程,该函数返回这线程的Handle,以后我们就可以用这个Handle来管理这个线程的。于是我们可以做一个类名为ThreadManager,来管理这些Handle,并随时监控这些线程的状态。
总的思想就是这样,不过为了方便使用,我们最好把这个类封装成DLL的形式,这样以后我们在任何程序中都可以很方便的用该类来管理线程了(当然如果你有兴趣,也可以用COM模型来实现)。
-We all know that in VC++, we can create a thread using CreateThread, the function returns this thread Handle, since we can use the Handle to manage this thread. So we can do a class called ThreadManager, to manage these Handle, and always monitor the status of these threads.
The overall idea is so, but for ease of use, we better package this class in the form of a DLL, so that later we can easily use this class to manage threads in any program (of course, if you are interested, too COM model can be used to achieve).
总的思想就是这样,不过为了方便使用,我们最好把这个类封装成DLL的形式,这样以后我们在任何程序中都可以很方便的用该类来管理线程了(当然如果你有兴趣,也可以用COM模型来实现)。
-We all know that in VC++, we can create a thread using CreateThread, the function returns this thread Handle, since we can use the Handle to manage this thread. So we can do a class called ThreadManager, to manage these Handle, and always monitor the status of these threads.
The overall idea is so, but for ease of use, we better package this class in the form of a DLL, so that later we can easily use this class to manage threads in any program (of course, if you are interested, too COM model can be used to achieve).
(系统自动生成,下载前可以参看下载内容)
下载文件列表
test4.txt