Skip to main content

FromValue

Trait FromValue 

Source
pub trait FromValue: Sealed {
    // Required method
    fn from_sql(val: Value) -> Result<Self>
       where Self: Sized;
}
Expand description

Convert a Value into the implementors type.

Required Methods§

Source

fn from_sql(val: Value) -> Result<Self>
where Self: Sized,

Dyn Compatibility§

This trait is dyn compatible.

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

Implementations on Foreign Types§

Source§

impl FromValue for Vec<u8>

Source§

fn from_sql(val: Value) -> Result<Self>

Source§

impl FromValue for bool

Source§

fn from_sql(val: Value) -> Result<Self>

Source§

impl FromValue for f64

Source§

fn from_sql(val: Value) -> Result<Self>

Source§

impl FromValue for i32

Source§

fn from_sql(val: Value) -> Result<Self>

Source§

impl FromValue for i64

Source§

fn from_sql(val: Value) -> Result<Self>

Source§

impl FromValue for u32

Source§

fn from_sql(val: Value) -> Result<Self>

Source§

impl FromValue for u64

Source§

fn from_sql(val: Value) -> Result<Self>

Source§

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

Source§

fn from_sql(val: Value) -> Result<Self>

Source§

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

Source§

fn from_sql(val: Value) -> Result<Self>

Implementors§