WaitHandleExtensions.SetSafeWaitHandle Method (WaitHandle, SafeWaitHandle)
.NET Framework (current version)
Sets a safe handle for a native operating system wait handle.
Assembly: mscorlib (in mscorlib.dll)
[SecurityCriticalAttribute] public static void SetSafeWaitHandle( this WaitHandle waitHandle, SafeWaitHandle value )
Parameters
- waitHandle
-
Type:
System.Threading.WaitHandle
A wait handle that encapsulates an operating system-specific object that waits for exclusive access to a shared resource.
- value
-
Type:
Microsoft.Win32.SafeHandles.SafeWaitHandle
The safe handle to wrap the operating system handle.
| Exception | Condition |
|---|---|
| ArgumentNullException | waitHandle is null. |
SetSafeWaitHandle is an extension method that is equivalent to assigning a value to the WaitHandle.SafeWaitHandle property.
Universal Windows Platform
Available since 10
.NET Framework
Available since 4.6
Available since 10
.NET Framework
Available since 4.6
Show: