Timeout.Infinite 欄位
定義
public: int Infinite = -1;
public const int Infinite = -1;
val mutable Infinite : int
Public Const Infinite As Integer = -1
欄位值
備註
對於接受millisecondsTimeout
參數的執行緒方法Thread.Sleep(Int32) (例如和Thread.Join(Int32)), 此值會用來無限期地暫停執行緒。For threading methods that accept a millisecondsTimeout
parameter, such as Thread.Sleep(Int32) and Thread.Join(Int32), this value is used to suspend the thread indefinitely. 不過, 在大部分的情況下System.Threading , 我們建議您使用其他類別 ( Mutex例如、 Monitor、 EventWaitHandle或Semaphore ) 來同步處理執行緒或管理資源。However, in most cases, we recommend that you use other System.Threading classes, such as Mutex, Monitor, EventWaitHandle, or Semaphore instead, to synchronize threads or manage resources.
此欄位的值為-1 (0xFFFFFFFF)。The value of this field is -1 (0xFFFFFFFF).