Skip to main content

TableLoaderSqlx

Trait TableLoaderSqlx 

Source
pub trait TableLoaderSqlx: Table {
    // Required methods
    fn load<'a>(
        &self,
        values: &mut impl Iterator<Item = PgValueRef<'a>>,
    ) -> Self::Result;
    fn skip<'a>(&self, values: &mut impl Iterator<Item = PgValueRef<'a>>);
}
Expand description

Trait allowing loading of Tables when using sqlx.

Required Methods§

Source

fn load<'a>( &self, values: &mut impl Iterator<Item = PgValueRef<'a>>, ) -> Self::Result

Load the table given an iterator over a row’s values

Source

fn skip<'a>(&self, values: &mut impl Iterator<Item = PgValueRef<'a>>)

discard N columns from the iterator ofer a row This is used when this value was discarded by a MaybeTable.

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementations on Foreign Types§

Source§

impl<T> TableLoaderSqlx for (T₁, T₂, …, Tₙ)
where T: TableLoaderSqlx,

Available on crate feature sqlx only.

This trait is implemented for tuples up to 15 items long.

Source§

fn load<'a>( &self, values: &mut impl Iterator<Item = PgValueRef<'a>>, ) -> Self::Result

Source§

fn skip<'a>(&self, values: &mut impl Iterator<Item = PgValueRef<'a>>)

Implementors§

Source§

impl<A, B, C> TableLoaderSqlx for Three<'static, ExprMode, A, B, C>
where A: Value, B: Value, C: Value,

Source§

impl<A, B> TableLoaderSqlx for Two<'static, ExprMode, A, B>
where A: Value, B: Value,

Source§

impl<A> TableLoaderSqlx for One<'static, ExprMode, A>
where A: Value,

Source§

impl<T: TableLoaderManySqlx> TableLoaderSqlx for ListTable<T>

Available on crate feature sqlx only.
Source§

impl<T: TableLoaderSqlx> TableLoaderSqlx for MaybeTable<'static, T>

Available on crate feature sqlx only.
Source§

impl<T: TableLoaderSqlx> TableLoaderSqlx for NullTable<'static, T>

Available on crate feature sqlx only.
Source§

impl<T: Value> TableLoaderSqlx for Expr<'static, T>

Available on crate feature sqlx only.
Source§

impl<T> TableLoaderSqlx for TableUsingMapper<T>
where T: Table + MapTable<'static> + TableHKT<Mode = ExprMode>,

Available on crate feature sqlx only.