Struct AsyncAwaiter
Provides an object that waits for the completion of an asynchronous operation. This type and its members are intended for compiler use only.
Implements
Inherited Members
System.ValueType.Equals(System.Object)
System.ValueType.GetHashCode()
System.ValueType.ToString()
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: UnityFx.Async.CompilerServices
Assembly: UnityFx.Async-netstandard2.0.dll
Syntax
public struct AsyncAwaiter : INotifyCompletion
Constructors
| Improve this Doc View SourceAsyncAwaiter(IAsyncOperation)
Initializes a new instance of the AsyncAwaiter struct.
Declaration
public AsyncAwaiter(IAsyncOperation op)
Parameters
Type | Name | Description |
---|---|---|
IAsyncOperation | op |
AsyncAwaiter(IAsyncOperation, SynchronizationContext)
Initializes a new instance of the AsyncAwaiter struct.
Declaration
public AsyncAwaiter(IAsyncOperation op, SynchronizationContext syncContext)
Parameters
Type | Name | Description |
---|---|---|
IAsyncOperation | op | |
SynchronizationContext | syncContext |
Properties
| Improve this Doc View SourceIsCompleted
Gets a value indicating whether the underlying operation is completed.
Declaration
public bool IsCompleted { get; }
Property Value
Type | Description |
---|---|
Boolean | The operation completion flag. |
Methods
| Improve this Doc View SourceGetResult()
Returns the source result value.
Declaration
public void GetResult()
OnCompleted(Action)
Declaration
public void OnCompleted(Action continuation)
Parameters
Type | Name | Description |
---|---|---|
Action | continuation |