JsonPath<T> class

Represents a json-pointer - can be used to do json-pointer operations on MModel instances.

T represents the type of data expected at this pointer

Inheritance
Available extensions

Constructors

JsonPath.fromJson(dynamic json)
factory
JsonPath.internal(List<String>? _segments, String path)
const
JsonPath.of(dynamic from, {JsonPath? relativeTo})
factory
JsonPath.parsed(String value, {JsonPath? relativeTo})
factory
JsonPath.root()
const
JsonPath.segments(List<String> segments)
JsonPath.single(String single)
const

Properties

chop JsonPath
Returns an immutable copy of this path, with the last path segment removed
no setter
diffHashCode int
no setterinherited
diffKey String
no setterinherited
diffSource → dynamic
no setterinherited
equalityHashCode int
no setterinherited
first String
The first segment in the path
no setter
hashCode int
The hash code for this object.
no setterinherited
isEmpty bool

Available on JsonPath<T>, provided by the JsonPathOperatorExtensions extension

Whether this path is empty, eg "/"
no setter
isKnown bool
no setterinherited
isNotRoot bool

Available on JsonPath<T>, provided by the JsonPathOperatorExtensions extension

no setter
isNullOrRoot bool

Available on JsonPath<T>?, provided by the JsonPathOperatorNullExtensions extension

no setter
last String
The last segment in the path
no setter
length int
no setter
path String
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
segments List<String>
no setter
self JsonPath<T>

Available on JsonPath<T>?, provided by the JsonPathOperatorNullExtensions extension

no setter
value String
finalinherited
verifyNotRoot JsonPath<T>

Available on JsonPath<T>, provided by the JsonPathOperatorExtensions extension

no setter

Methods

cast<TT>() JsonPath<TT>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
plus<TT>(JsonPath<TT> path) JsonPath<TT>

Available on JsonPath<T>, provided by the JsonPathOperatorExtensions extension

relativize<TT>(JsonPath other) JsonPath<TT>
startsWith(JsonPath otherPath) bool
Whether this path starts with another JsonPath instance.
toJson() → dynamic
toKey() String
toString() String
A string representation of this object.
override

Operators

operator +(dynamic path) JsonPath

Available on JsonPath<T>, provided by the JsonPathOperatorExtensions extension

operator ==(Object other) bool
The equality operator.
inherited
operator [](int index) → dynamic

Constants

Root → const JsonPath