RequestDelegateFactory.InferMetadata 方法

定义

返回为 RequestDelegate 创建的 自动推断的 Create(Delegate, RequestDelegateFactoryOptions, RequestDelegateMetadataResult)元数据。 这包括由 参数推断和IEndpointParameterMetadataProvider实现的IEndpointMetadataProvider元数据,并将类型返回给 methodInfo

public static Microsoft.AspNetCore.Http.RequestDelegateMetadataResult InferMetadata (System.Reflection.MethodInfo methodInfo, Microsoft.AspNetCore.Http.RequestDelegateFactoryOptions? options = default);
static member InferMetadata : System.Reflection.MethodInfo * Microsoft.AspNetCore.Http.RequestDelegateFactoryOptions -> Microsoft.AspNetCore.Http.RequestDelegateMetadataResult
Public Shared Function InferMetadata (methodInfo As MethodInfo, Optional options As RequestDelegateFactoryOptions = Nothing) As RequestDelegateMetadataResult

参数

返回

RequestDelegateMetadataResult要传递给 的 Create(Delegate, RequestDelegateFactoryOptions, RequestDelegateMetadataResult)

适用于