C++ Builder 参考手册 ➙ System::Classes ➙ TThread ➙ Resume
头文件:#include <System.Classes.hpp>
命名空间:System::Classes
类:TThread
访问权限:public:
函数原型:
void __fastcall Resume(void);
Resume 是 System::Classes::TThread 的成员函数,继续执行已经挂起的线程,这是过时的方法。
参数:
无。
返回值:
无。
- Resume 和 Suspend 是过时的方法,调用 Resume 恢复用 Suspend 挂起的线程;
- 线程的挂起和继续仅用来调试程序使用,用 Suspend 挂起的线程可能会引起线程死锁,正式运行的线程需要用其他同步方式暂停,比如等待一个事件;
- 调用 Suspend 方法挂起多少次,就要 Resume 多少次线程才可以恢复执行。
相关:
- System::Classes::TThread::Start
- System::Classes::TThread::Started
- System::Classes::TThread::Suspend
- System::Classes::TThread::Suspended
- System::Classes::TThread::Terminate
- System::Classes::TThread::Terminated
- System::Classes::TThread::Finished
- System::Classes::TThread::Execute
- System::Classes::TThread
- System::Syncobjs::TEvent
- System::Syncobjs::TMutex
- System::Syncobjs::TCriticalSection
- System::TObject
- VCL 类继承关系
C++ Builder 参考手册 ➙ System::Classes ➙ TThread ➙ Resume
网友评论