pub trait DbIntrospector: Send + Sync {
// Required methods
fn query_tables<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<TableRow>, Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn query_relationships<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<RelationshipRow>, Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn query_routines<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<RoutineRow>, Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn query_computed_fields<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<ComputedFieldRow>, Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn query_timezones<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
Trait for database introspection
This trait abstracts database queries for schema introspection, allowing the schema cache to be tested without a real database connection.
Required Methods§
Sourcefn query_tables<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<TableRow>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn query_tables<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<TableRow>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Query all tables and views in the specified schemas
Sourcefn query_relationships<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<RelationshipRow>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn query_relationships<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<RelationshipRow>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Query all foreign key relationships
Sourcefn query_routines<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<RoutineRow>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn query_routines<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<RoutineRow>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Query all routines (functions/procedures) in the specified schemas
Sourcefn query_computed_fields<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<ComputedFieldRow>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn query_computed_fields<'life0, 'life1, 'async_trait>(
&'life0 self,
schemas: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<ComputedFieldRow>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Query computed field functions in the specified schemas