pub struct MySQLConnection {
pub conn: Arc<Mutex<Conn>>,
}Available on crate feature
mysql only.Fields§
§conn: Arc<Mutex<Conn>>Trait Implementations§
Source§impl<'a> AsyncDbConnection<Conn, &'a (dyn ToValue + Sync)> for MySQLConnection
impl<'a> AsyncDbConnection<Conn, &'a (dyn ToValue + Sync)> for MySQLConnection
fn new(conn: Conn) -> 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 [&'a (dyn ToValue + Sync)],
projected_schema: Option<SchemaRef>,
) -> Pin<Box<dyn Future<Output = Result<SendableRecordBatchStream, GenericError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: '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 [&'a (dyn ToValue + Sync)],
projected_schema: Option<SchemaRef>,
) -> Pin<Box<dyn Future<Output = Result<SendableRecordBatchStream, GenericError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: '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,
query: &'life1 str,
params: &'life2 [&'a (dyn ToValue + Sync)],
) -> Pin<Box<dyn Future<Output = Result<u64, GenericError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn execute<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
query: &'life1 str,
params: &'life2 [&'a (dyn ToValue + Sync)],
) -> Pin<Box<dyn Future<Output = Result<u64, GenericError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: '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<'a> DbConnection<Conn, &'a (dyn ToValue + Sync)> for MySQLConnection
impl<'a> DbConnection<Conn, &'a (dyn ToValue + Sync)> for MySQLConnection
Auto Trait Implementations§
impl Freeze for MySQLConnection
impl !RefUnwindSafe for MySQLConnection
impl Send for MySQLConnection
impl Sync for MySQLConnection
impl Unpin for MySQLConnection
impl !UnwindSafe for MySQLConnection
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