Skip to main content

Class: InfixExpression

jsonpath.expressions.InfixExpression

Base class for all filter expressions.

Hierarchy

Constructors

constructor

new InfixExpression(token, left, operator, right): InfixExpression

Parameters

NameType
tokenToken
leftFilterExpression
operatorstring
rightFilterExpression

Returns

InfixExpression

Overrides

FilterExpression.constructor

Defined in

src/path/expression.ts:123

Properties

left

Readonly left: FilterExpression

Defined in

src/path/expression.ts:125


logical

Readonly logical: boolean

Defined in

src/path/expression.ts:121


operator

Readonly operator: string

Defined in

src/path/expression.ts:126


Readonly right: FilterExpression

Defined in

src/path/expression.ts:127


token

Readonly token: Token

Inherited from

FilterExpression.token

Defined in

src/path/expression.ts:124

Methods

evaluate

evaluate(context): boolean

Evaluate the filter expression in the given context.

Parameters

NameTypeDescription
contextFilterContextEvaluation context.

Returns

boolean

Overrides

FilterExpression.evaluate

Defined in

src/path/expression.ts:133


toString

toString(): string

Return a string representation of the expression.

Returns

string

Overrides

FilterExpression.toString

Defined in

src/path/expression.ts:161