Record Class MergePatchError.DuplicateName
java.lang.Object
java.lang.Record
ca.marcusdunn.jsonlens.mergepatch.MergePatchError.DuplicateName
- Record Components:
path- the location of the object in the patch documentname- the duplicate name
- All Implemented Interfaces:
MergePatchError
- Enclosing interface:
MergePatchError
public static record MergePatchError.DuplicateName(List<String> path, String name)
extends Record
implements MergePatchError
An object of the patch document has a member name more than once.
RFC 7396 does not tell which of the values applies, and RFC 8259 (Section 4) does not
define the meaning of duplicate names. Thus JsonMergePatch.parse(P, JsonModel) rejects the patch
document. The check includes the objects in arrays, which a merge copies to the target.
-
Nested Class Summary
Nested classes/interfaces inherited from interface MergePatchError
MergePatchError.DuplicateName, MergePatchError.TargetDuplicateName, MergePatchError.ValueNotRepresentable -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.name()Returns the value of thenamerecord component.path()Returns the value of thepathrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from interface MergePatchError
message
-
Constructor Details
-
DuplicateName
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
path
-
name
-