コード例 #1
0
        public static void ResetEvent(WaitableObject waitableObject)
        {
            Debug.Assert(waitableObject != null);

            s_lock.Acquire();
            try
            {
                waitableObject.UnsignalEvent();
            }
            finally
            {
                s_lock.Release();
            }
        }
コード例 #2
0
        public static void ResetEvent(IntPtr handle)
        {
            WaitableObject waitableObject = HandleManager.FromHandle(handle);

            s_lock.Acquire();
            try
            {
                waitableObject.UnsignalEvent();
            }
            finally
            {
                s_lock.Release();
            }
        }
コード例 #3
0
        public static void ResetEvent(WaitableObject waitableObject)
        {
            Debug.Assert(waitableObject != null);

            LockHolder lockHolder = new LockHolder(s_lock);

            try
            {
                waitableObject.UnsignalEvent(ref lockHolder);
            }
            finally
            {
                lockHolder.Dispose();
            }
        }