Trait diesel:: types:: FromSql
[−]
[src]
pub trait FromSql<A, DB: Backend + HasSqlType<A>>: Sized { fn from_sql(bytes: Option<&DB::RawValue>) -> Result<Self, Box<Error + Send + Sync>>; }
How to deserialize a single field of a given type. The input will always be the binary representation, not the text.
Required Methods
Implementors
impl FromSql<VarChar, Sqlite> for String
impl FromSql<Binary, Sqlite> for Vec<u8>
impl FromSql<SmallInt, Sqlite> for i16
impl FromSql<Integer, Sqlite> for i32
impl FromSql<Bool, Sqlite> for bool
impl FromSql<BigInt, Sqlite> for i64
impl FromSql<Float, Sqlite> for f32
impl FromSql<Double, Sqlite> for f64