Skip to main content

ToSql

Trait ToSql 

pub trait ToSql {
    // Required method
    fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>;
}
Expand description

A trait for types that can be converted into SQLite values. Returns crate::Error::ToSqlConversionFailure if the conversion fails.

Required Methods§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

Converts Rust value to SQLite value

Implementations on Foreign Types§

Source§

impl ToSql for Audience

§

impl ToSql for bool

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for f32

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for f64

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for i8

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for i16

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for i32

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for i64

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for isize

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for str

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for u8

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for u16

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for u32

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

Source§

impl ToSql for CircleId

Source§

impl ToSql for DeviceId

A device id as its eight big-endian bytes, as coven_devices holds it: the whole 64-bit id, which an SQL integer would hold only as a signed number.

Source§

impl ToSql for FileId

A file id as canonical UUID text, as coven_files and the app’s file columns hold it.

Source§

impl ToSql for KeyId

A store or circle key’s id as its sixteen bytes, as coven’s key columns hold it.

Source§

impl ToSql for MemberId

A member id as canonical UUID text, as coven’s member columns and the coven_members view hold it.

Source§

impl ToSql for ObjectId

A stored object’s id as its sixteen bytes, as coven’s object columns hold it.

Source§

impl ToSql for StoreId

A store id as its sixteen bytes, as _coven_store holds it.

Source§

impl ToSql for UuidText

§

impl ToSql for String

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for Vec<u8>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for NonZero<i8>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for NonZero<i16>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for NonZero<i32>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for NonZero<i64>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for NonZero<isize>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for NonZero<u8>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for NonZero<u16>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for NonZero<u32>

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl ToSql for [u8]

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl<T> ToSql for Cow<'_, T>
where T: ToSql + ToOwned + ?Sized,

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl<T> ToSql for Option<T>
where T: ToSql,

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl<T> ToSql for &T
where T: ToSql + ?Sized,

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl<T> ToSql for Box<T>
where T: ToSql + ?Sized,

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl<T> ToSql for Rc<T>
where T: ToSql + ?Sized,

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl<T> ToSql for Arc<T>
where T: ToSql + ?Sized,

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

§

impl<const N: usize> ToSql for [u8; N]

§

fn to_sql(&self) -> Result<ToSqlOutput<'_>, Error>

Implementors§

§

impl ToSql for ToSqlOutput<'_>

§

impl ToSql for Value

Source§

impl ToSql for MoveId

A move id bound and read as an SQL integer, as coven_uploads.move and coven_pending.move hold it for the app’s cancel_move (E4).

§

impl ToSql for Null

§

impl ToSql for SqlFnArg

§

impl ToSql for ZeroBlob