Skip to main content

PhysicalTextRetrieval

Trait PhysicalTextRetrieval 

Source
pub trait PhysicalTextRetrieval: Sync {
    // Required methods
    fn validate_text_search_field(
        &self,
        table: &str,
        field: &str,
    ) -> Result<(), SQLError>;
    fn fts_fields_for_table(&self, table: &str) -> Result<Vec<String>, SQLError>;
    fn bayesian_params_for_relation(
        &self,
        table: &str,
        signal_table: &str,
        field: &str,
    ) -> Result<BayesianBM25Params, SQLError>;
    fn search_leaf(
        &self,
        table: &str,
        field: &str,
        query: &str,
        mode: &ScoringMode,
        limit: usize,
        top_k: Option<TextTopKPlan>,
    ) -> Result<Vec<ScoredEntry>, SQLError>;
    fn visit_search_leaf(
        &self,
        table: &str,
        field: &str,
        query: &str,
        mode: &ScoringMode,
        visitor: &mut dyn FnMut(ScoredEntry) -> Result<(), SQLError>,
    ) -> Result<(), SQLError>;
}

Required Methods§

Source

fn validate_text_search_field( &self, table: &str, field: &str, ) -> Result<(), SQLError>

Source

fn fts_fields_for_table(&self, table: &str) -> Result<Vec<String>, SQLError>

Source

fn bayesian_params_for_relation( &self, table: &str, signal_table: &str, field: &str, ) -> Result<BayesianBM25Params, SQLError>

Source

fn search_leaf( &self, table: &str, field: &str, query: &str, mode: &ScoringMode, limit: usize, top_k: Option<TextTopKPlan>, ) -> Result<Vec<ScoredEntry>, SQLError>

Source

fn visit_search_leaf( &self, table: &str, field: &str, query: &str, mode: &ScoringMode, visitor: &mut dyn FnMut(ScoredEntry) -> Result<(), SQLError>, ) -> Result<(), SQLError>

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§