Expand description
TreeNode based visiting and rewriting for LogicalPlans
Visiting (read only) APIs
LogicalPlan::visit: recursively visit the node and all of its inputsLogicalPlan::visit_with_subqueries: recursively visit the node and all of its inputs, including subqueriesLogicalPlan::apply_children: recursively visit all inputs of this nodeLogicalPlan::apply_expressions: (non recursively) visit all expressions of this nodeLogicalPlan::apply_subqueries: (non recursively) visit all subqueries of this nodeLogicalPlan::apply_with_subqueries: recursively visit all inputs and embedded subqueries.
Rewriting (update) APIs:
LogicalPlan::exists: search for an expression in a planLogicalPlan::rewrite: recursively rewrite the node and all of its inputsLogicalPlan::map_children: recursively rewrite all inputs of this nodeLogicalPlan::map_expressions: (non recursively) visit all expressions of this nodeLogicalPlan::map_subqueries: (non recursively) rewrite all subqueries of this nodeLogicalPlan::rewrite_with_subqueries: recursively rewrite the node and all of its inputs, including subqueries
(Re)creation APIs (these require substantial cloning and thus are slow):
LogicalPlan::with_new_exprs: Create a new plan with different expressionsLogicalPlan::expressions: Return a copy of the plan’s expressions
Macros§
- handle_
transform_ 🔒recursion - This macro is used to determine continuation during combined transforming traversals.
Functions§
- rewrite_
extension_ 🔒inputs - Rewrites all inputs for an Extension node “in place” (it currently has to copy values because there are no APIs for in place modification)