jmespath.cpp
C++ implementation of JMESPath, a query language for JSON http://jmespath.org
|
The IndexExpressionNode class represents a JMESPath index expression. More...
#include <indexexpressionnode.h>
Public Member Functions | |
IndexExpressionNode () | |
Construct an empty IndexExpressionNode object. More... | |
IndexExpressionNode (const BracketSpecifierNode &bracketNode) | |
Constructs an IndexExpressionNode object with the given bracketSpecifier and empty left and right expressions. More... | |
IndexExpressionNode (const ExpressionNode &left, const BracketSpecifierNode &bracketNode, const ExpressionNode &right={}) | |
Constructs an IndexExpressionNode with given expression as its left hand expression, subexpression as its right hand expression and with the given bracketSpecifier. More... | |
bool | operator== (const IndexExpressionNode &other) const |
Equality compares this node to the other. More... | |
bool | isProjection () const override |
Returns whather this expression requires the projection of subsequent expressions. More... | |
bool | stopsProjection () const override |
Reports whether the node should stop an ongoing projection or not. More... | |
void | accept (interpreter::AbstractVisitor *visitor) const override |
Calls the visit method of the given visitor with the dynamic type of the node. More... | |
![]() | |
BinaryExpressionNode () | |
Constructs an empty BinaryExpressionNode object. More... | |
BinaryExpressionNode (const ExpressionNode &left, const ExpressionNode &right) | |
Constructs a BinaryExpressionNode object with the given leftExpressin and rightExpression as its children. More... | |
bool | operator== (const BinaryExpressionNode &other) const |
Equality compares this node to the other. More... | |
![]() | |
AbstractNode ()=default | |
Constructs an AbstractNode object. More... | |
AbstractNode (const AbstractNode &)=default | |
Copy-constructs an AbstractNode object. More... | |
virtual | ~AbstractNode () |
Destroys the AbstractNode object. More... | |
AbstractNode & | operator= (const AbstractNode &)=default |
Copy-assigns the other object to this object. More... | |
Public Attributes | |
BracketSpecifierNode | bracketSpecifier |
The bracket specifier in an index expression. More... | |
![]() | |
ExpressionNode | leftExpression |
The left hand expression of the node. More... | |
ExpressionNode | rightExpression |
The right hand expression of the node. More... | |
The IndexExpressionNode class represents a JMESPath index expression.
jmespath::ast::IndexExpressionNode::IndexExpressionNode | ( | ) |
Construct an empty IndexExpressionNode object.
jmespath::ast::IndexExpressionNode::IndexExpressionNode | ( | const BracketSpecifierNode & | bracketNode | ) |
Constructs an IndexExpressionNode object with the given bracketSpecifier and empty left and right expressions.
[in] | bracketNode | The bracket specifier node. |
jmespath::ast::IndexExpressionNode::IndexExpressionNode | ( | const ExpressionNode & | left, |
const BracketSpecifierNode & | bracketNode, | ||
const ExpressionNode & | right = {} |
||
) |
Constructs an IndexExpressionNode with given expression as its left hand expression, subexpression as its right hand expression and with the given bracketSpecifier.
[in] | left | The left hand expression of the node. |
[in] | bracketNode | The index expression's bracket specifier. |
[in] | right | The right hand expression of the node. |
|
overridevirtual |
Calls the visit method of the given visitor with the dynamic type of the node.
[in] | visitor | A visitor implementation |
Reimplemented from jmespath::ast::BinaryExpressionNode.
|
overridevirtual |
Returns whather this expression requires the projection of subsequent expressions.
Implements jmespath::ast::BinaryExpressionNode.
bool jmespath::ast::IndexExpressionNode::operator== | ( | const IndexExpressionNode & | other | ) | const |
Equality compares this node to the other.
[in] | other | The node that should be compared. |
|
overridevirtual |
Reports whether the node should stop an ongoing projection or not.
Implements jmespath::ast::BinaryExpressionNode.
BracketSpecifierNode jmespath::ast::IndexExpressionNode::bracketSpecifier |
The bracket specifier in an index expression.