-
- All Implemented Interfaces:
public interface PatchPatch interface that allows easy creation of patch operations.
This interface is used by the Sunday generator to generate patch types.
-
-
Method Summary
Modifier and Type Method Description <T extends Any> PatchOp.Set<T>set(T value)Creates a JSON Merge Patch PatchOp.Set operation from the provided value that sets/replaces the current value. <T extends Any> PatchOp.Delete<T>delete()Creates a JSON Merge Patch PatchOp.Delete operation that deletes the current value. <T extends Any> PatchOp.None<T>none()Creates a JSON Merge Patch PatchOp.None operation that leaves the current value untouched. <T extends Any> PatchOp<T>setOrDelete(T value)Creates a JSON Merge Patch PatchOp.Set or PatchOp.Delete operation from the provided value. -
-
Method Detail
-
set
<T extends Any> PatchOp.Set<T> set(T value)
Creates a JSON Merge Patch PatchOp.Set operation from the provided value that sets/replaces the current value.
- Parameters:
value- Value to set/replace the current value with.
-
delete
<T extends Any> PatchOp.Delete<T> delete()
Creates a JSON Merge Patch PatchOp.Delete operation that deletes the current value.
-
none
<T extends Any> PatchOp.None<T> none()
Creates a JSON Merge Patch PatchOp.None operation that leaves the current value untouched.
-
setOrDelete
<T extends Any> PatchOp<T> setOrDelete(T value)
Creates a JSON Merge Patch PatchOp.Set or PatchOp.Delete operation from the provided value. If the value provided is not
nulla PatchOp.Set operation is created to set/replace the current value. Alternatively, when the provided value isnulla PatchOp.Delete operation is created to delete the current value.- Parameters:
value- Value to set/replace the current value or delete the current value.
-
-
-
-