System.Threading.NativeEventCalls.SetEvent_internal C# (CSharp) Method

SetEvent_internal() private method

private SetEvent_internal ( IntPtr handle ) : bool
handle System.IntPtr
return bool
		public static extern bool SetEvent_internal(IntPtr handle);

Usage Example

        internal void Wait(object state)
        {
            try
            {
                WaitHandle[] waits = new WaitHandle[] { _waitObject, _cancelEvent };
                do
                {
                    int signal = WaitHandle.WaitAny(waits, _timeout, false);
                    if (!_unregistered)
                    {
                        lock (this)
                        {
                            _callsInProcess++;
                        }
                        ThreadPool.QueueUserWorkItem(new WaitCallback(DoCallBack), (signal == WaitHandle.WaitTimeout));
                    }
                }while (!_unregistered && !_executeOnlyOnce);
            }
            catch {}

            lock (this)
            {
                _unregistered = true;
                if (_callsInProcess == 0 && _finalEvent != null)
                {
                    NativeEventCalls.SetEvent_internal(_finalEvent.Handle);
                }
            }
        }
All Usage Examples Of System.Threading.NativeEventCalls::SetEvent_internal