Binds a parameter of a method boundary advice to the AsyncCallId that identifies the current execution of an async method.
Namespace: PostSharp.Aspects.Advices
Assembly: PostSharp.dll
Syntax
public sealed class AsyncCallIdAttribute : AdviceParameterAttributeRemarks
All the advices of one execution of the async method receive the same value, so the identifier can correlate the events of this execution,
for instance in a log. The parameter must be of type AsyncCallId, and it cannot be ref, in or out.
This attribute can be used in the method boundary advices. When the target method is not transformed as an async method, for instance
when it is an iterator, the parameter receives the default value of AsyncCallId, unless IsRequired is true.
Constructors
| Name | Description |
|---|---|
| AsyncCallIdAttribute() |
Properties
| Name | Description |
|---|---|
| IsRequired | Gets or sets a value indicating whether the target must be an async method. When this property is |