共用方式為


DefaultProblemDetailsFactory 建構函式

定義

初始化 DefaultProblemDetailsFactory 類別的新實例。

public DefaultProblemDetailsFactory (Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Mvc.ApiBehaviorOptions> options, Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.ProblemDetailsOptions>? problemDetailsOptions = default);
new Microsoft.AspNetCore.Mvc.Infrastructure.DefaultProblemDetailsFactory : Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Mvc.ApiBehaviorOptions> * Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.ProblemDetailsOptions> -> Microsoft.AspNetCore.Mvc.Infrastructure.DefaultProblemDetailsFactory
Public Sub New (options As IOptions(Of ApiBehaviorOptions), Optional problemDetailsOptions As IOptions(Of ProblemDetailsOptions) = Nothing)

參數

options
IOptions<ApiBehaviorOptions>

API 行為的選項。

problemDetailsOptions
IOptions<ProblemDetailsOptions>

自定義問題詳細數據的選項。

適用於