1.词汇
- thread 线程
- delegate 委托
- constructor 构造函数
2.例句
-
A delegate in C# allows you to specify a sequence of actions to be executed at the appropriate time. Delegates are typically used when the code that wants to execute the actions doesn’t know the details of what those actions should be.
在C#下的委托允许你在恰当的时间执行一系列操作。如果代码需要执行一些不知道细节的操作,一般就应该使用委托来实现。
-
For instance, the only reason why the Thread class knows what to run in a new thread when you start it is because you provide the constructor with a ThreadStart or ParameterizedThreadStart delegate instance.
比如,Thread类之所以知道新线程里运行了什么,唯一的理由是当它启动一个新的线程的时候,通过构造函数向他提供了一个ThreadStart或ParameterizedThreadStart的委托实例。