共用方式為


InvalidModelStateResult(ModelStateDictionary, Boolean) 建構函式

定義

初始化 InvalidModelStateResult 類別的新執行個體。

public InvalidModelStateResult (Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary modelState, bool includeErrorDetail);
new System.Web.Http.InvalidModelStateResult : Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary * bool -> System.Web.Http.InvalidModelStateResult
Public Sub New (modelState As ModelStateDictionary, includeErrorDetail As Boolean)

參數

modelState
ModelStateDictionary

要包含在錯誤中的模型狀態。

includeErrorDetail
Boolean

true 如果錯誤應該包含例外狀況訊息,則為 ;否則為 false

適用於