Skip to main content

Class: RelativeQuery

jsonpath.expressions.RelativeQuery

Base class for relative and absolute JSONPath query expressions.

Hierarchy

Constructors

constructor

new RelativeQuery(token, path): RelativeQuery

Parameters

NameType
tokenToken
pathJSONPath

Returns

RelativeQuery

Inherited from

JSONPathQuery.constructor

Defined in

src/path/expression.ts:194

Properties

path

Readonly path: JSONPath

Inherited from

JSONPathQuery.path

Defined in

src/path/expression.ts:196


token

Readonly token: Token

Inherited from

JSONPathQuery.token

Defined in

src/path/expression.ts:195

Methods

evaluate

evaluate(context): JSONPathNodeList

Evaluate the filter expression in the given context.

Parameters

NameTypeDescription
contextFilterContextEvaluation context.

Returns

JSONPathNodeList

Overrides

JSONPathQuery.evaluate

Defined in

src/path/expression.ts:203


toString

toString(): string

Return a string representation of the expression.

Returns

string

Overrides

JSONPathQuery.toString

Defined in

src/path/expression.ts:211