- TThread::Started - C++ Builder
- TThread::~TThread - C++ Builder
- TThread::TThread - C++ Builder
- TThread::NameThreadForDebugging
- TThread::Suspended - C++ Builder
- TThread::Terminate - C++ Builder
- TThread::CurrentThread - C++ Bui
- TThread::ExternalThread - C++ Bu
- TThread::FatalException - C++ Bu
- TThread::GetSystemTimes - C++ Bu
C++ Builder 参考手册 ➙ System::Classes ➙ TThread ➙ Started
头文件:#include <System.Classes.hpp>
命名空间:System::Classes
类:TThread
访问权限:public:
属性定义:
__property bool Started = { read = FStarted, nodefault };
Started 是 System::Classes::TThread 的属性,线程已经开始运行。
- 线程的构造函数的参数 CreateSuspended 如果为 false,线程创建之后是挂起状态,没有开始运行,需要 Start 方法开始运行;
- 如果 FreeOnTerminate 属性置为 true,Execute 方法执行结束,线程就会被销毁,所以构造函数的参数要为 true 即创建出来的时候线程挂起,然后用 Start 方法开始执行,调用 Start 方法之后,就不要在 Execute 方法之外的任何地方调用类的成员了,除非确认这个对象还没被销毁。
相关:
- System::Classes::TThread::Start
- System::Classes::TThread::Terminate
- System::Classes::TThread::Terminated
- System::Classes::TThread::Finished
- System::Classes::TThread::Execute
- System::Classes::TThread::OnTerminate
- System::Classes::TThread::FreeOnTerminate
- System::Classes::TThread::FatalException
- System::Classes::TThread::TThread
- System::Classes::TThread
- System::TObject
- VCL 类继承关系
C++ Builder 参考手册 ➙ System::Classes ➙ TThread ➙ Started
网友评论