Share via


TargetingHttpContextMiddleware.InvokeAsync Method

Definition

Adds targeting information to the HTTP context.

public System.Threading.Tasks.Task InvokeAsync(Microsoft.AspNetCore.Http.HttpContext httpContext, Microsoft.FeatureManagement.FeatureFilters.ITargetingContextAccessor targetingContextAccessor);
member this.InvokeAsync : Microsoft.AspNetCore.Http.HttpContext * Microsoft.FeatureManagement.FeatureFilters.ITargetingContextAccessor -> System.Threading.Tasks.Task
Public Function InvokeAsync (httpContext As HttpContext, targetingContextAccessor As ITargetingContextAccessor) As Task

Parameters

httpContext
HttpContext

The HttpContext to add the targeting information to.

targetingContextAccessor
ITargetingContextAccessor

The ITargetingContextAccessor to retrieve the targeting information from.

Returns

Exceptions

Thrown if the provided context or targetingContextAccessor is null.

Applies to