pub fn optimize_children(
optimizer: &impl OptimizerRule,
plan: &LogicalPlan,
config: &dyn OptimizerConfig,
) -> Result<Option<LogicalPlan>, DataFusionError>
👎Deprecated since 40.0.0: please use OptimizerRule::apply_order with ApplyOrder::BottomUp instead
Expand description
Convenience rule for writing optimizers: recursively invoke
optimize on plan’s children and then return a node of the same
type. Useful for optimizer rules which want to leave the type
of plan unchanged but still apply to the children.
This also handles the case when the plan
is a LogicalPlan::Explain
.
Returning Ok(None)
indicates that the plan can’t be optimized by the optimizer
.