Skip to main content

SqlTransport

Trait SqlTransport 

Source
pub trait SqlTransport: Send + Sync {
    type Error: Error + Send + Sync + 'static;

    // Required methods
    fn fetch_all_sql(
        &self,
        query: &CompiledQuery,
    ) -> impl Future<Output = Result<Vec<Record>, Self::Error>> + Send;
    fn execute_sql(
        &self,
        query: &CompiledQuery,
    ) -> impl Future<Output = Result<u64, Self::Error>> + Send;
}

Required Associated Types§

Source

type Error: Error + Send + Sync + 'static

Required Methods§

Source

fn fetch_all_sql( &self, query: &CompiledQuery, ) -> impl Future<Output = Result<Vec<Record>, Self::Error>> + Send

Source

fn execute_sql( &self, query: &CompiledQuery, ) -> impl Future<Output = Result<u64, Self::Error>> + Send

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementors§