Binds a parameter of an OnMethodYieldAdvice method to the task awaited by the async method.
Namespace: PostSharp.Aspects.Advices
Assembly: PostSharp.dll
Syntax
public sealed class AwaitedTaskAttribute : AdviceParameterAttributeRemarks
The parameter must be of type Task, IAsyncResult or object, and it cannot be ref, in or
out. Its value can be null when the
awaited object is not a Task, for instance when the method awaits Yield(). This attribute
can be used only in OnMethodYieldAdvice.
Constructors
| Name | Description |
|---|---|
| AwaitedTaskAttribute() |