Compartir a través de


IEndpointSelectorPolicy.ApplyAsync Método

Definición

Sobrecargas

ApplyAsync(HttpContext, CandidateSet)

Aplica la directiva a CandidateSet.

ApplyAsync(HttpContext, EndpointSelectorContext, CandidateSet)

Aplica la directiva a CandidateSet.

ApplyAsync(HttpContext, CandidateSet)

Source:
IEndpointSelectorPolicy.cs

Aplica la directiva a CandidateSet.

public:
 System::Threading::Tasks::Task ^ ApplyAsync(Microsoft::AspNetCore::Http::HttpContext ^ httpContext, Microsoft::AspNetCore::Routing::Matching::CandidateSet ^ candidates);
public System.Threading.Tasks.Task ApplyAsync (Microsoft.AspNetCore.Http.HttpContext httpContext, Microsoft.AspNetCore.Routing.Matching.CandidateSet candidates);
abstract member ApplyAsync : Microsoft.AspNetCore.Http.HttpContext * Microsoft.AspNetCore.Routing.Matching.CandidateSet -> System.Threading.Tasks.Task
Public Function ApplyAsync (httpContext As HttpContext, candidates As CandidateSet) As Task

Parámetros

httpContext
HttpContext

asociado HttpContext a la solicitud actual.

Devoluciones

Comentarios

Las implementaciones de IEndpointSelectorPolicy deben implementar este método y filtrar el conjunto de candidatos en estableciendo SetValidity(Int32, Boolean)candidatesfalse en donde lo desee.

Para indicar una condición de error, IEndpointSelectorPolicy debe asignar el punto de conexión llamando SetEndpoint(HttpContext, Endpoint) a y estableciendo RouteValues en un Endpoint valor que generará el error deseado cuando se ejecute.

Se aplica a

ApplyAsync(HttpContext, EndpointSelectorContext, CandidateSet)

Aplica la directiva a CandidateSet.

public:
 System::Threading::Tasks::Task ^ ApplyAsync(Microsoft::AspNetCore::Http::HttpContext ^ httpContext, Microsoft::AspNetCore::Routing::EndpointSelectorContext ^ context, Microsoft::AspNetCore::Routing::Matching::CandidateSet ^ candidates);
public System.Threading.Tasks.Task ApplyAsync (Microsoft.AspNetCore.Http.HttpContext httpContext, Microsoft.AspNetCore.Routing.EndpointSelectorContext context, Microsoft.AspNetCore.Routing.Matching.CandidateSet candidates);
abstract member ApplyAsync : Microsoft.AspNetCore.Http.HttpContext * Microsoft.AspNetCore.Routing.EndpointSelectorContext * Microsoft.AspNetCore.Routing.Matching.CandidateSet -> System.Threading.Tasks.Task
Public Function ApplyAsync (httpContext As HttpContext, context As EndpointSelectorContext, candidates As CandidateSet) As Task

Parámetros

httpContext
HttpContext

asociado HttpContext a la solicitud actual.

context
EndpointSelectorContext

asociado EndpointSelectorContext a la solicitud actual.

Devoluciones

Comentarios

Las implementaciones de IEndpointSelectorPolicy deben implementar este método y filtrar el conjunto de candidatos en estableciendo SetValidity(Int32, Boolean)candidatesfalse en donde lo desee.

Para indicar una condición de error, establezca Endpoint en un Endpoint valor que generará el error deseado cuando se ejecute.

Se aplica a