JsonPatchDocument Sınıf

Tanım

C#
[Newtonsoft.Json.JsonConverter(typeof(Microsoft.AspNetCore.JsonPatch.Converters.JsonPatchDocumentConverter))]
public class JsonPatchDocument : Microsoft.AspNetCore.JsonPatch.IJsonPatchDocument
Devralma
JsonPatchDocument
Öznitelikler
Newtonsoft.Json.JsonConverterAttribute
Uygulamalar

Oluşturucular

Özellikler

Yöntemler

Add(String, Object)

İşlem ekleme. Sonuç olarak{ "op": "add", "path": "/a/b/c", "value": [ "foo", "bar" ] }

ApplyTo(Object, Action<JsonPatchError>)

Bu JsonPatchDocument'ı uygula

ApplyTo(Object, IObjectAdapter, Action<JsonPatchError>)

Bu JsonPatchDocument'ı uygula

ApplyTo(Object, IObjectAdapter)

Bu JsonPatchDocument'ı uygula

ApplyTo(Object)

Bu JsonPatchDocument'ı uygula

Copy(String, String)

Belirtilen konumdaki değeri hedef konuma kopyalayın. Sonuç olarak: { "op": "copy", "from": "/a/b/c", "path": "/a/b/e" }

Move(String, String)

Belirtilen konumdaki değeri kaldırır ve hedef konuma ekler. Sonuç olarak: { "op": "move", "from": "/a/b/c", "path": "/a/b/d" }

Remove(String)

Hedef konumdaki değeri kaldırın. Sonuç olarak { "op": "remove", "path": "/a/b/c" }

Replace(String, Object)

değeri değiştirin. Sonuç olarak { "op": "replace", "path": "/a/b/c", "value": 42 }

Test(String, Object)

Test değeri. Sonuç olarak { "op": "test", "path": "/a/b/c", "value": 42 }

Belirtik Arabirim Kullanımları

Şunlara uygulanır

Ürün Sürümler
ASP.NET Core 1.0, 1.1, 2.0, 2.1, 2.2, 3.0, 3.1, 5.0, 6.0, 7.0, 8.0, 9.0