问题描述
.NET BCL中有一个CurrentThread和一个ProcessThread对象.这些有什么区别?
In the .NET BCL, there is a CurrentThread and a ProcessThread object. What is the difference between these?
谢谢
推荐答案
System.Threading.Thread
类上的 CurrentThread
静态属性是当前CLR System.Threading.Thread
实例.CLR线程是对基础win32线程的抽象. System.Diagnostics.ProcessThread
类提供对win32线程的一种访问,主要用于性能跟踪.
The CurrentThread
static property on the System.Threading.Thread
class is the current CLR System.Threading.Thread
instance. The CLR Thread is an abstraction over the underlying win32 thread. The System.Diagnostics.ProcessThread
class gives one access to the win32 threads, largely for perfomance tracking.
CLR线程的主要区别在于它们不是固定在win32线程上的.
A key distinction of CLR threads is that they are not fixed to win32 threads.
这篇关于CurrentThread/ProcessThread对象的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!