System.IAsyncResult.AsyncWaitHandle Property

Gets a System.Threading.WaitHandle that is used to wait for an asynchronous operation to complete.

Syntax

public System.Threading.WaitHandle AsyncWaitHandle { get; }

Value

A System.Threading.WaitHandle that is signaled when an asynchronous operation completes.

Remarks

The return value allows the client to wait for an asynchronous operation to complete instead of polling IAsyncResult.IsCompleted until the operation concludes. The return value can be used to perform a System.Threading.WaitHandle.WaitOne(int, bool), System.Threading.WaitHandle.WaitAny(System.Threading.WaitHandle[], int, bool), or System.Threading.WaitHandle.WaitAll(System.Threading.WaitHandle[], int, bool) operation.

The common language runtime supplies a number of waitable objects, such as System.Threading.ManualResetEvent, System.Threading.AutoResetEvent, and System.Threading.Mutex, all of which mirror Win32 synchronization primitives.

Requirements

Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0