pub trait ExecutablePlanOptimizer {
// Required methods
fn plan_for_execution(
&self,
plan: UnifiedPlan,
params: &[SQLParam],
) -> Result<UnifiedPlan, SQLError>;
fn plan_with_result(
&self,
plan: UnifiedPlan,
params: &[SQLParam],
) -> Result<(UnifiedPlan, AnalyzedResult), SQLError>;
// Provided method
fn plan_for_statement_cache(
&self,
plan: UnifiedPlan,
params: &[SQLParam],
) -> Result<(UnifiedPlan, bool), SQLError> { ... }
}Expand description
Analyze and optimize a logical plan using metadata captured for this call.
Required Methods§
fn plan_for_execution( &self, plan: UnifiedPlan, params: &[SQLParam], ) -> Result<UnifiedPlan, SQLError>
Sourcefn plan_with_result(
&self,
plan: UnifiedPlan,
params: &[SQLParam],
) -> Result<(UnifiedPlan, AnalyzedResult), SQLError>
fn plan_with_result( &self, plan: UnifiedPlan, params: &[SQLParam], ) -> Result<(UnifiedPlan, AnalyzedResult), SQLError>
Analyze and optimize a logical plan, and return what its analysis derives about its result.
Provided Methods§
Sourcefn plan_for_statement_cache(
&self,
plan: UnifiedPlan,
params: &[SQLParam],
) -> Result<(UnifiedPlan, bool), SQLError>
fn plan_for_statement_cache( &self, plan: UnifiedPlan, params: &[SQLParam], ) -> Result<(UnifiedPlan, bool), SQLError>
Return an executable and whether its analysis inputs permit reuse across ordinary messages. Planners without that evidence must analyze again.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".