The InsertNodeAction class is a functor for inserting the given node into the AST whose root node is specified with targetNode.
More...
#include <insertnodeaction.h>
|
NodeInserterT | m_nodeInserter |
| Functor for inserting the a node at the position of the target node into the AST. More...
|
|
NodeInsertConditionT | m_insertCondition |
| Functor for checking whether the passed node can be inserted at the position of the target node. More...
|
|
template<typename NodeInserterT, typename NodeInsertConditionT>
class jmespath::parser::InsertNodeAction< NodeInserterT, NodeInsertConditionT >
The InsertNodeAction class is a functor for inserting the given node into the AST whose root node is specified with targetNode.
The functor iterates over the left edge of the AST and if NodeInsertConditionT returns true for the given combination of targetNode and node the node will be inserted using NodeInserterT. If NodeInsertConditionT returns false it will try to insert node at the next location on the left edge of the AST.
- Template Parameters
-
NodeInserterT | Policy type for inserting the a node at the position of the target node into the AST. The functor should have an overloaded function call operator with a signature of void(ast::ExpressionNode* targetNode, T* node) const. |
NodeInsertConditionT | Policy type for checking whether the passed node can be inserted at the position of the target node. The functor should have an overloaded function call operator with a signature of bool(ast::ExpressionNode* targetNode, T* node) const. |
template<typename NodeInserterT , typename NodeInsertConditionT >
The action's result type.
template<typename NodeInserterT , typename NodeInsertConditionT >
template<typename T >
Inserts the given node into the AST whose root node is specified with targetNode.
- Parameters
-
[in] | targetNode | The root node of the AST. |
[in] | node | The node which should be inserted. |
template<typename NodeInserterT , typename NodeInsertConditionT >
Functor for checking whether the passed node can be inserted at the position of the target node.
template<typename NodeInserterT , typename NodeInsertConditionT >
Functor for inserting the a node at the position of the target node into the AST.
The documentation for this class was generated from the following file: