CreateManualResetEvent() public static method

Create a new ManualResetEvent object
public static CreateManualResetEvent ( bool initialState ) : ManualResetEvent
initialState bool
return System.Threading.ManualResetEvent
Esempio n. 1
0
 /// <summary>
 /// A wait handle to wait for completion, cancel, or timeout
 /// </summary>
 private WaitHandle GetWaitHandle()
 {
     lock (this)
     {
         if (null == _workItemCompleted)
         {
             _workItemCompleted = EventWaitHandleFactory.CreateManualResetEvent(IsCompleted);
         }
         ++_workItemCompletedRefCount;
     }
     return(_workItemCompleted);
 }