GenericSqlWriter

Struct GenericSqlWriter 

Source
pub struct GenericSqlWriter;

Implementations§

Source§

impl GenericSqlWriter

Source

pub fn new() -> Self

Trait Implementations§

Source§

impl SqlWriter for GenericSqlWriter

Source§

fn as_dyn(&self) -> &dyn SqlWriter

Source§

fn alias_declaration(&self, context: &mut Context) -> bool

Source§

fn write_escaped( &self, _context: &mut Context, buff: &mut String, value: &str, search: char, replace: &str, )

Source§

fn write_identifier_quoted( &self, context: &mut Context, buff: &mut String, value: &str, )

Source§

fn write_table_ref( &self, context: &mut Context, buff: &mut String, value: &TableRef, )

Source§

fn write_column_ref( &self, context: &mut Context, buff: &mut String, value: &ColumnRef, )

Source§

fn write_column_type( &self, context: &mut Context, buff: &mut String, value: &Value, )

Source§

fn write_value(&self, context: &mut Context, buff: &mut String, value: &Value)

Source§

fn write_value_none(&self, _context: &mut Context, buff: &mut String)

Source§

fn write_value_bool( &self, _context: &mut Context, buff: &mut String, value: bool, )

Source§

fn write_value_infinity( &self, context: &mut Context, buff: &mut String, negative: bool, )

Source§

fn write_value_string( &self, _context: &mut Context, buff: &mut String, value: &str, )

Source§

fn write_value_blob( &self, _context: &mut Context, buff: &mut String, value: &[u8], )

Source§

fn write_value_date( &self, _context: &mut Context, buff: &mut String, value: &Date, timestamp: bool, )

Source§

fn write_value_time( &self, _context: &mut Context, buff: &mut String, value: &Time, timestamp: bool, )

Source§

fn write_value_timestamp( &self, context: &mut Context, buff: &mut String, value: &PrimitiveDateTime, )

Source§

fn write_value_timestamptz( &self, context: &mut Context, buff: &mut String, value: &OffsetDateTime, )

Source§

fn value_interval_units(&self) -> &[(&str, i128)]

Source§

fn write_value_interval( &self, _context: &mut Context, buff: &mut String, value: &Interval, )

Source§

fn write_value_list<'a>( &self, context: &mut Context, buff: &mut String, value: Either<&Box<[Value]>, &Vec<Value>>, _ty: &Value, )

Source§

fn write_value_map( &self, context: &mut Context, buff: &mut String, value: &HashMap<Value, Value>, )

Source§

fn write_value_struct( &self, context: &mut Context, buff: &mut String, value: &Vec<(String, Value)>, )

Source§

fn expression_unary_op_precedence<'a>(&self, value: &UnaryOpType) -> i32

Source§

fn expression_binary_op_precedence<'a>(&self, value: &BinaryOpType) -> i32

Source§

fn write_expression_operand( &self, context: &mut Context, buff: &mut String, value: &Operand<'_>, )

Source§

fn write_expression_operand_question_mark( &self, _context: &mut Context, buff: &mut String, )

Source§

fn write_expression_unary_op( &self, context: &mut Context, buff: &mut String, value: &UnaryOp<&dyn Expression>, )

Source§

fn write_expression_binary_op( &self, context: &mut Context, buff: &mut String, value: &BinaryOp<&dyn Expression, &dyn Expression>, )

Source§

fn write_expression_ordered( &self, context: &mut Context, buff: &mut String, value: &Ordered<&dyn Expression>, )

Source§

fn write_join_type( &self, _context: &mut Context, buff: &mut String, join_type: &JoinType, )

Source§

fn write_join( &self, context: &mut Context, buff: &mut String, join: &Join<&dyn DataSet, &dyn DataSet, &dyn Expression>, )

Source§

fn write_transaction_begin(&self, buff: &mut String)

Source§

fn write_transaction_commit(&self, buff: &mut String)

Source§

fn write_transaction_rollback(&self, buff: &mut String)

Source§

fn write_create_schema<E>(&self, buff: &mut String, if_not_exists: bool)
where Self: Sized, E: Entity,

Source§

fn write_drop_schema<E>(&self, buff: &mut String, if_exists: bool)
where Self: Sized, E: Entity,

Source§

fn write_create_table<E>(&self, buff: &mut String, if_not_exists: bool)
where Self: Sized, E: Entity,

Source§

fn write_column_comments<E>(&self, context: &mut Context, buff: &mut String)
where Self: Sized, E: Entity,

Source§

fn write_create_table_column_fragment( &self, context: &mut Context, buff: &mut String, column: &ColumnDef, )
where Self: Sized,

Source§

fn write_create_table_references_action( &self, _context: &mut Context, buff: &mut String, action: &Action, )

Source§

fn write_drop_table<E>(&self, buff: &mut String, if_exists: bool)
where Self: Sized, E: Entity,

Source§

fn write_select<Item, Cols, Data, Cond>( &self, buff: &mut String, columns: Cols, from: &Data, condition: &Cond, limit: Option<u32>, )
where Self: Sized, Item: Expression, Cols: IntoIterator<Item = Item> + Clone, Data: DataSet, Cond: Expression,

Source§

fn write_insert<'b, E, It>(&self, buff: &mut String, entities: It, update: bool)
where Self: Sized, E: Entity + 'b, It: IntoIterator<Item = &'b E>,

Source§

fn write_insert_update_fragment<'a, E, It>( &self, context: &mut Context, buff: &mut String, columns: It, )
where Self: Sized, E: Entity, It: Iterator<Item = &'a ColumnDef>,

Source§

fn write_delete<E, Expr>(&self, buff: &mut String, condition: &Expr)
where Self: Sized, E: Entity, Expr: Expression,

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.