IMiddleware.InvokeAsync(HttpContext, RequestDelegate) 方法

定义

请求处理方法。

public:
 System::Threading::Tasks::Task ^ InvokeAsync(Microsoft::AspNetCore::Http::HttpContext ^ context, Microsoft::AspNetCore::Http::RequestDelegate ^ next);
public System.Threading.Tasks.Task InvokeAsync (Microsoft.AspNetCore.Http.HttpContext context, Microsoft.AspNetCore.Http.RequestDelegate next);
abstract member InvokeAsync : Microsoft.AspNetCore.Http.HttpContext * Microsoft.AspNetCore.Http.RequestDelegate -> System.Threading.Tasks.Task
Public Function InvokeAsync (context As HttpContext, next As RequestDelegate) As Task

参数

context
HttpContext

当前请求的 HttpContext

next
RequestDelegate

表示请求管道中剩余中间件的委托。

返回

一个 Task ,表示此中间件的执行。

适用于