pub trait DynPlanParentReduceRule:
Debug
+ Send
+ Sync
+ 'static {
// Required methods
fn matches(&self, child: &PlanRef, parent: &PlanRef) -> bool;
fn reduce_parent(
&self,
child: &PlanRef,
parent: &PlanRef,
child_idx: usize,
) -> VortexResult<Option<PlanRef>>;
}Expand description
Type-erased interface used by PlanParentRuleSet.
Required Methods§
Sourcefn matches(&self, child: &PlanRef, parent: &PlanRef) -> bool
fn matches(&self, child: &PlanRef, parent: &PlanRef) -> bool
Returns whether this rule supports the concrete child and parent operators.
Sourcefn reduce_parent(
&self,
child: &PlanRef,
parent: &PlanRef,
child_idx: usize,
) -> VortexResult<Option<PlanRef>>
fn reduce_parent( &self, child: &PlanRef, parent: &PlanRef, child_idx: usize, ) -> VortexResult<Option<PlanRef>>
Attempts to replace parent based on child at child_idx.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".