pub enum OwnedSQLChunk<V: SQLParam> {
Token(Token),
Ident(String),
Raw(String),
Param(OwnedParam<V>),
Table(&'static dyn SQLTableInfo),
Column(&'static dyn SQLColumnInfo),
Alias {
inner: Box<OwnedSQLChunk<V>>,
alias: String,
},
}Expand description
Owned version of SQLChunk with ’static lifetime
Variants§
Token(Token)
Ident(String)
Raw(String)
Param(OwnedParam<V>)
Table(&'static dyn SQLTableInfo)
Column(&'static dyn SQLColumnInfo)
Alias
Implementations§
Source§impl<V: SQLParam> OwnedSQLChunk<V>
impl<V: SQLParam> OwnedSQLChunk<V>
Sourcepub const fn table(table: &'static dyn SQLTableInfo) -> Self
pub const fn table(table: &'static dyn SQLTableInfo) -> Self
Creates a table chunk.
Sourcepub const fn column(column: &'static dyn SQLColumnInfo) -> Self
pub const fn column(column: &'static dyn SQLColumnInfo) -> Self
Creates a column chunk.
Sourcepub fn ident(name: impl Into<String>) -> Self
pub fn ident(name: impl Into<String>) -> Self
Creates a quoted identifier from a runtime string.
Sourcepub fn param(value: OwnedParam<V>) -> Self
pub fn param(value: OwnedParam<V>) -> Self
Creates a parameter chunk with owned value.
Sourcepub fn alias(inner: OwnedSQLChunk<V>, alias: impl Into<String>) -> Self
pub fn alias(inner: OwnedSQLChunk<V>, alias: impl Into<String>) -> Self
Creates an alias chunk wrapping any OwnedSQLChunk.
Trait Implementations§
Source§impl<V: Clone + SQLParam> Clone for OwnedSQLChunk<V>
impl<V: Clone + SQLParam> Clone for OwnedSQLChunk<V>
Source§fn clone(&self) -> OwnedSQLChunk<V>
fn clone(&self) -> OwnedSQLChunk<V>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<V: SQLParam> From<OwnedSQLChunk<V>> for SQLChunk<'static, V>
impl<V: SQLParam> From<OwnedSQLChunk<V>> for SQLChunk<'static, V>
Source§fn from(value: OwnedSQLChunk<V>) -> Self
fn from(value: OwnedSQLChunk<V>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<V> Freeze for OwnedSQLChunk<V>where
V: Freeze,
impl<V> !RefUnwindSafe for OwnedSQLChunk<V>
impl<V> Send for OwnedSQLChunk<V>where
V: Send,
impl<V> Sync for OwnedSQLChunk<V>where
V: Sync,
impl<V> Unpin for OwnedSQLChunk<V>where
V: Unpin,
impl<V> !UnwindSafe for OwnedSQLChunk<V>
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