pub struct MysqlGenerator {}Trait Implementations§
Source§impl Generator for MysqlGenerator
impl Generator for MysqlGenerator
async fn query_columns( &self, conn_url: &str, table_name: &str, ) -> Vec<ColumnInfo>
fn get_mapping_type(&self, sql_type: &str) -> String
fn gen_insert_returning_id_fn( &self, table_name: &str, column_infos: &Vec<ColumnInfo>, ) -> String
fn gen_insert_fn( &self, table_name: &str, column_infos: &Vec<ColumnInfo>, ) -> String
fn gen_batch_insert_returning_id_fn( &self, table_name: &str, column_infos: &Vec<ColumnInfo>, ) -> String
fn gen_batch_insert_fn( &self, table_name: &str, column_infos: &Vec<ColumnInfo>, ) -> String
fn gen_select_by_id_fn( &self, table_name: &str, column_infos: &Vec<ColumnInfo>, ) -> String
fn gen_delete_by_id_fn(&self, _table_name: &str) -> String
Source§fn gen_file(
&self,
conn_url: &str,
table_name: &str,
) -> impl Future<Output = Result<(), Error>> + Sendwhere
Self: Sync,
fn gen_file(
&self,
conn_url: &str,
table_name: &str,
) -> impl Future<Output = Result<(), Error>> + Sendwhere
Self: Sync,
This is a tool for gen table_name mapping Struct and basic sql, such as insert. Read more
fn gen_struct(&self, table_name: &str, column_infos: &Vec<ColumnInfo>) -> String
fn gen_struct_name(&self, table: &str) -> String
fn gen_field_and_value_str( &self, column_infos: &Vec<ColumnInfo>, contain_id: bool, ) -> String
fn gen_field_and_batch_values_str( &self, column_infos: &Vec<ColumnInfo>, contain_id: bool, ) -> String
fn gen_select_sql( &self, table_name: &str, column_infos: &Vec<ColumnInfo>, ) -> String
fn gen_select_sql_fn( &self, table_name: &str, column_infos: &Vec<ColumnInfo>, ) -> String
fn gen_delete_by_id_sql(&self, table_name: &str) -> String
Auto Trait Implementations§
impl Freeze for MysqlGenerator
impl RefUnwindSafe for MysqlGenerator
impl Send for MysqlGenerator
impl Sync for MysqlGenerator
impl Unpin for MysqlGenerator
impl UnwindSafe for MysqlGenerator
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 more