JsonPointerSegment class

JSON Pointer containing at least one reference

Implemented types

Constructors

JsonPointerSegment(String token, JsonPointer parent)

Properties

hashCode int
hashCode of the given path determines equality
no setteroverride
parent JsonPointer
The parent pointer. In the empty pointer this property is null.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

add(Object? document, Object? newValue) Object?
Returns a copy of document with the newValue added at the referenced location.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
read(Object? document, {Object? orElse()?}) Object?
Reads the referenced value from the document. If no value is referenced, gets the value from orElse or throws BadRoute.
override
remove(Object? document) Object?
Returns a copy of document with the value at the referenced location removed. This method returns null if the entire document is referenced (i.e. JSON Path expression is an empty string).
override
toJson() String
inherited
toString() String
A string representation of this object.
override
write(Object? document, Object? newValue) Object?
Returns a copy of document with the referenced value set to newValue.
override

Operators

operator ==(Object otherPointer) bool
Compares the pointer paths for equality
override