Trait diesel::types::FromSql
[−]
[src]
pub trait FromSql<A: NativeSqlType>: Sized { fn from_sql(bytes: Option<&[u8]>) -> Result<Self, Box<Error>>; }
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<T, ST> FromSql<Array<ST>> for Vec<T> where T: FromSql<ST>, ST: NativeSqlType
impl FromSql<Timestamp> for PgTimestamp
impl FromSql<Date> for PgDate
impl FromSql<Time> for PgTime
impl FromSql<Interval> for PgInterval
impl FromSql<Float> for f32
impl FromSql<Double> for f64
impl FromSql<Numeric> for PgNumeric
impl FromSql<SmallInt> for i16
impl FromSql<Integer> for i32
impl FromSql<BigInt> for i64
impl FromSql<Oid> for u32
impl<T, ST> FromSql<Nullable<ST>> for Option<T> where T: FromSql<ST>, ST: NativeSqlType
impl FromSql<Bool> for bool
impl FromSql<VarChar> for String
impl FromSql<Text> for String
impl FromSql<Binary> for Vec<u8>
impl<'a, T: ?Sized, ST> FromSql<ST> for Cow<'a, T> where ST: NativeSqlType, T: 'a + ToOwned, T::Owned: FromSql<ST>