Skip to main content

PlannedIndex

Trait PlannedIndex 

Source
pub trait PlannedIndex:
    Send
    + Sync
    + Debug {
    // Required methods
    fn kinds(&self) -> &[IndexKind];
    fn entries(&self) -> &[PlanEntry];
    fn build<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        context: &'life1 BuildContext<'life2>,
    ) -> Pin<Box<dyn Future<Output = Result<Option<Box<dyn IndexCreator>>, BoxedError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
    fn is_current(&self, file: &FileMeta, context: &PlanContext<'_>) -> bool;

    // Provided methods
    fn needs_input_reuse(&self) -> bool { ... }
    fn memory_limit(&self) -> Option<usize> { ... }
}
Expand description

An immutable typed plan shared by output files of an operation.

Required Methods§

Source

fn kinds(&self) -> &[IndexKind]

Nonempty, unique subset of the handler’s kinds, including removal plans.

Source

fn entries(&self) -> &[PlanEntry]

Requested column formats. Every entry kind must belong to this plan.

Source

fn build<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, context: &'life1 BuildContext<'life2>, ) -> Pin<Box<dyn Future<Output = Result<Option<Box<dyn IndexCreator>>, BoxedError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Prepares input reuse before any output batch is consumed.

Source

fn is_current(&self, file: &FileMeta, context: &PlanContext<'_>) -> bool

Whether persisted entries satisfy this plan. The context uses the same file’s indexes as the planning input.

Provided Methods§

Source

fn needs_input_reuse(&self) -> bool

Whether building this plan can reuse persisted input summaries. Row-only plans do not require checking input object existence.

Source

fn memory_limit(&self) -> Option<usize>

Optional hard ceiling; built-in creators use their existing spill budgets.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§