pub trait ContextProvider {
    // Required methods
    fn get_table_provider(
        &self,
        name: TableReference<'_>
    ) -> Result<Arc<dyn TableSource>>;
    fn get_function_meta(&self, name: &str) -> Option<Arc<ScalarUDF>>;
    fn get_aggregate_meta(&self, name: &str) -> Option<Arc<AggregateUDF>>;
    fn get_window_meta(&self, name: &str) -> Option<Arc<WindowUDF>>;
    fn get_variable_type(&self, variable_names: &[String]) -> Option<DataType>;
    fn options(&self) -> &ConfigOptions;
}
Expand description

The ContextProvider trait allows the query planner to obtain meta-data about tables and functions referenced in SQL statements

Required Methods§

source

fn get_table_provider( &self, name: TableReference<'_> ) -> Result<Arc<dyn TableSource>>

Getter for a datasource

source

fn get_function_meta(&self, name: &str) -> Option<Arc<ScalarUDF>>

Getter for a UDF description

source

fn get_aggregate_meta(&self, name: &str) -> Option<Arc<AggregateUDF>>

Getter for a UDAF description

source

fn get_window_meta(&self, name: &str) -> Option<Arc<WindowUDF>>

Getter for a UDWF

source

fn get_variable_type(&self, variable_names: &[String]) -> Option<DataType>

Getter for system/user-defined variable type

source

fn options(&self) -> &ConfigOptions

Get configuration options

Implementors§