pub struct SqliteConnection {
pub conn: Connection,
}Available on crate feature
sqlite only.Fields§
§conn: ConnectionTrait Implementations§
Source§impl AsyncDbConnection<Connection, &'static (dyn ToSql + Sync)> for SqliteConnection
impl AsyncDbConnection<Connection, &'static (dyn ToSql + Sync)> for SqliteConnection
fn new(conn: Connection) -> Self
fn tables<'life0, 'life1, 'async_trait>(
&'life0 self,
_schema: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn schemas<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn get_schema<'life0, 'life1, 'async_trait>(
&'life0 self,
table_reference: &'life1 TableReference,
) -> Pin<Box<dyn Future<Output = Result<SchemaRef, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_schema<'life0, 'life1, 'async_trait>(
&'life0 self,
table_reference: &'life1 TableReference,
) -> Pin<Box<dyn Future<Output = Result<SchemaRef, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get the schema for a table reference. Read more
Source§fn query_arrow<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
sql: &'life1 str,
params: &'life2 [&'static (dyn ToSql + Sync)],
projected_schema: Option<SchemaRef>,
) -> Pin<Box<dyn Future<Output = Result<SendableRecordBatchStream, GenericError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn query_arrow<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
sql: &'life1 str,
params: &'life2 [&'static (dyn ToSql + Sync)],
projected_schema: Option<SchemaRef>,
) -> Pin<Box<dyn Future<Output = Result<SendableRecordBatchStream, GenericError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Query the database with the given SQL statement and parameters, returning a
Result of SendableRecordBatchStream. Read moreSource§fn execute<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
sql: &'life1 str,
params: &'life2 [&'static (dyn ToSql + Sync)],
) -> Pin<Box<dyn Future<Output = Result<u64, GenericError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn execute<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
sql: &'life1 str,
params: &'life2 [&'static (dyn ToSql + Sync)],
) -> Pin<Box<dyn Future<Output = Result<u64, GenericError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Execute the given SQL statement with parameters, returning the number of affected rows. Read more
Source§impl DbConnection<Connection, &'static (dyn ToSql + Sync)> for SqliteConnection
impl DbConnection<Connection, &'static (dyn ToSql + Sync)> for SqliteConnection
Source§impl SchemaValidator for SqliteConnection
impl SchemaValidator for SqliteConnection
Source§fn is_data_type_supported(data_type: &DataType) -> bool
fn is_data_type_supported(data_type: &DataType) -> bool
Available on crate features
sqlite or duckdb or postgres only.Source§fn unsupported_type_error(data_type: &DataType, field_name: &str) -> Self::Error
fn unsupported_type_error(data_type: &DataType, field_name: &str) -> Self::Error
Available on crate features
sqlite or duckdb or postgres only.Source§fn is_field_supported(field: &Arc<Field>) -> bool
fn is_field_supported(field: &Arc<Field>) -> bool
Available on crate features
sqlite or duckdb or postgres only.Source§fn is_schema_supported(schema: &SchemaRef) -> bool
fn is_schema_supported(schema: &SchemaRef) -> bool
Available on crate features
sqlite or duckdb or postgres only.Source§fn handle_unsupported_schema(
schema: &SchemaRef,
unsupported_type_action: UnsupportedTypeAction,
) -> Result<SchemaRef, Self::Error>
fn handle_unsupported_schema( schema: &SchemaRef, unsupported_type_action: UnsupportedTypeAction, ) -> Result<SchemaRef, Self::Error>
Available on crate features
sqlite or duckdb or postgres only.For a given input schema, rebuild it according to the
UnsupportedTypeAction.
Implemented for a specific connection type, that connection determines which types it supports.
If the UnsupportedTypeAction is Error/String, the function will return an error if the schema contains an unsupported data type.
If the UnsupportedTypeAction is Warn, the function will log a warning if the schema contains an unsupported data type and remove the column.
If the UnsupportedTypeAction is Ignore, the function will remove the column silently. Read moreAuto Trait Implementations§
impl Freeze for SqliteConnection
impl RefUnwindSafe for SqliteConnection
impl Send for SqliteConnection
impl Sync for SqliteConnection
impl Unpin for SqliteConnection
impl UnwindSafe for SqliteConnection
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request