WaitHandleExtensions.GetSafeWaitHandle(WaitHandle) WaitHandleExtensions.GetSafeWaitHandle(WaitHandle) WaitHandleExtensions.GetSafeWaitHandle(WaitHandle) Method

定義

取得原生作業系統等候控制代碼的安全控制代碼。Gets the safe handle for a native operating system wait handle.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Win32::SafeHandles::SafeWaitHandle ^ GetSafeWaitHandle(System::Threading::WaitHandle ^ waitHandle);
[System.Security.SecurityCritical]
public static Microsoft.Win32.SafeHandles.SafeWaitHandle GetSafeWaitHandle (this System.Threading.WaitHandle waitHandle);
static member GetSafeWaitHandle : System.Threading.WaitHandle -> Microsoft.Win32.SafeHandles.SafeWaitHandle

參數

waitHandle
WaitHandle WaitHandle WaitHandle

原生作業系統控制代碼。A native operating system handle.

傳回

包裝原生作業系統等候控制代碼的安全等候控制代碼。The safe wait handle that wraps the native operating system wait handle.

例外狀況

waitHandlenullwaitHandle is null.

備註

GetSafeWaitHandle 是擴充方法,相當於擷取的值WaitHandle.SafeWaitHandle屬性。GetSafeWaitHandle is an extension method that is equivalent to retrieving the value of the WaitHandle.SafeWaitHandle property.

適用於