RequestDelegateFactory.Create Metoda

Definice

Přetížení

Create(Delegate, RequestDelegateFactoryOptions)

Vytvoří implementaci RequestDelegate pro handler.

Create(MethodInfo, Func<HttpContext,Object>, RequestDelegateFactoryOptions)

Vytvoří implementaci RequestDelegate pro methodInfo.

Create(Delegate, RequestDelegateFactoryOptions)

Vytvoří implementaci RequestDelegate pro handler.

public static Microsoft.AspNetCore.Http.RequestDelegateResult Create (Delegate handler, Microsoft.AspNetCore.Http.RequestDelegateFactoryOptions? options = default);
static member Create : Delegate * Microsoft.AspNetCore.Http.RequestDelegateFactoryOptions -> Microsoft.AspNetCore.Http.RequestDelegateResult
Public Shared Function Create (handler As Delegate, Optional options As RequestDelegateFactoryOptions = Nothing) As RequestDelegateResult

Parametry

handler
Delegate

Obslužná rutina požadavku s libovolným počtem vlastních parametrů, které často vytváří odpověď s vrácenou hodnotou.

options
RequestDelegateFactoryOptions

Používá RequestDelegateFactoryOptions se ke konfiguraci chování obslužné rutiny.

Návraty

RequestDelegateResult

Hodnota RequestDelegateResult

Platí pro

Create(MethodInfo, Func<HttpContext,Object>, RequestDelegateFactoryOptions)

Vytvoří implementaci RequestDelegate pro methodInfo.

public static Microsoft.AspNetCore.Http.RequestDelegateResult Create (System.Reflection.MethodInfo methodInfo, Func<Microsoft.AspNetCore.Http.HttpContext,object>? targetFactory = default, Microsoft.AspNetCore.Http.RequestDelegateFactoryOptions? options = default);
static member Create : System.Reflection.MethodInfo * Func<Microsoft.AspNetCore.Http.HttpContext, obj> * Microsoft.AspNetCore.Http.RequestDelegateFactoryOptions -> Microsoft.AspNetCore.Http.RequestDelegateResult
Public Shared Function Create (methodInfo As MethodInfo, Optional targetFactory As Func(Of HttpContext, Object) = Nothing, Optional options As RequestDelegateFactoryOptions = Nothing) As RequestDelegateResult

Parametry

methodInfo
MethodInfo

Obslužná rutina požadavku s libovolným počtem vlastních parametrů, které často vytváří odpověď s vrácenou hodnotou.

targetFactory
Func<HttpContext,Object>

Vytvoří pro ne statickou metodu this .

options
RequestDelegateFactoryOptions

Používá RequestDelegateFactoryOptions se ke konfiguraci chování obslužné rutiny.

Návraty

RequestDelegateResult

Hodnota RequestDelegate

Platí pro