JsonPatchExtensions.ApplyTo 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
ApplyTo<T>(JsonPatchDocument<T>, T, ModelStateDictionary) |
在 物件上套用 JSON 修補作業,並在 中 ModelStateDictionary 記錄錯誤。 |
ApplyTo<T>(JsonPatchDocument<T>, T, ModelStateDictionary, String) |
在 物件上套用 JSON 修補作業,並在 中 ModelStateDictionary 記錄錯誤。 |
ApplyTo<T>(JsonPatchDocument<T>, T, ModelStateDictionary)
在 物件上套用 JSON 修補作業,並在 中 ModelStateDictionary 記錄錯誤。
public:
generic <typename T>
where T : class[System::Runtime::CompilerServices::Extension]
static void ApplyTo(Microsoft::AspNetCore::JsonPatch::JsonPatchDocument<T> ^ patchDoc, T objectToApplyTo, Microsoft::AspNetCore::Mvc::ModelBinding::ModelStateDictionary ^ modelState);
public static void ApplyTo<T> (this Microsoft.AspNetCore.JsonPatch.JsonPatchDocument<T> patchDoc, T objectToApplyTo, Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary modelState) where T : class;
static member ApplyTo : Microsoft.AspNetCore.JsonPatch.JsonPatchDocument<'T (requires 'T : null)> * 'T * Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary -> unit (requires 'T : null)
<Extension()>
Public Sub ApplyTo(Of T As Class) (patchDoc As JsonPatchDocument(Of T), objectToApplyTo As T, modelState As ModelStateDictionary)
類型參數
- T
參數
- patchDoc
- JsonPatchDocument<T>
- objectToApplyTo
- T
套用的 JsonPatchDocument<TModel> 實體。
- modelState
- ModelStateDictionary
要 ModelStateDictionary 加入錯誤的 。
適用於
ApplyTo<T>(JsonPatchDocument<T>, T, ModelStateDictionary, String)
在 物件上套用 JSON 修補作業,並在 中 ModelStateDictionary 記錄錯誤。
public:
generic <typename T>
where T : class[System::Runtime::CompilerServices::Extension]
static void ApplyTo(Microsoft::AspNetCore::JsonPatch::JsonPatchDocument<T> ^ patchDoc, T objectToApplyTo, Microsoft::AspNetCore::Mvc::ModelBinding::ModelStateDictionary ^ modelState, System::String ^ prefix);
public static void ApplyTo<T> (this Microsoft.AspNetCore.JsonPatch.JsonPatchDocument<T> patchDoc, T objectToApplyTo, Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary modelState, string prefix) where T : class;
static member ApplyTo : Microsoft.AspNetCore.JsonPatch.JsonPatchDocument<'T (requires 'T : null)> * 'T * Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary * string -> unit (requires 'T : null)
<Extension()>
Public Sub ApplyTo(Of T As Class) (patchDoc As JsonPatchDocument(Of T), objectToApplyTo As T, modelState As ModelStateDictionary, prefix As String)
類型參數
- T
參數
- patchDoc
- JsonPatchDocument<T>
- objectToApplyTo
- T
套用的 JsonPatchDocument<TModel> 實體。
- modelState
- ModelStateDictionary
要 ModelStateDictionary 加入錯誤的 。
- prefix
- String
在 中 ModelStateDictionary 查閱值時要使用的前置詞。