共用方式為


ProblemDetailsServiceCollectionExtensions.AddProblemDetails 方法

定義

多載

AddProblemDetails(IServiceCollection)

新增建立 ProblemDetails 失敗要求所需的服務。

AddProblemDetails(IServiceCollection, Action<ProblemDetailsOptions>)

新增建立 ProblemDetails 失敗要求所需的服務。

AddProblemDetails(IServiceCollection)

來源:
ProblemDetailsServiceCollectionExtensions.cs

新增建立 ProblemDetails 失敗要求所需的服務。

public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddProblemDetails (this Microsoft.Extensions.DependencyInjection.IServiceCollection services);
static member AddProblemDetails : Microsoft.Extensions.DependencyInjection.IServiceCollection -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddProblemDetails (services As IServiceCollection) As IServiceCollection

參數

services
IServiceCollection

要新增服務的 IServiceCollection

傳回

IServiceCollection,以便鏈結其他呼叫。

適用於

AddProblemDetails(IServiceCollection, Action<ProblemDetailsOptions>)

來源:
ProblemDetailsServiceCollectionExtensions.cs

新增建立 ProblemDetails 失敗要求所需的服務。

public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddProblemDetails (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.AspNetCore.Http.ProblemDetailsOptions>? configure);
static member AddProblemDetails : Microsoft.Extensions.DependencyInjection.IServiceCollection * Action<Microsoft.AspNetCore.Http.ProblemDetailsOptions> -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddProblemDetails (services As IServiceCollection, configure As Action(Of ProblemDetailsOptions)) As IServiceCollection

參數

services
IServiceCollection

要新增服務的 IServiceCollection

configure
Action<ProblemDetailsOptions>

ProblemDetailsOptions 設定服務的 。

傳回

IServiceCollection,以便鏈結其他呼叫。

適用於