[−][src]Struct mysql_async::Deserialized
Use it to parse T: Deserialize
from Value
.
ⓘThis example is not tested
#[derive(Deserialize)] struct DeserializableStruct { // ... } // ... let (Deserialized(val),): (Deserialized<DeserializableStruct>,) = from_row(row_with_single_json_column);
Trait Implementations
impl<T> Hash for Deserialized<T> where
T: Hash,
[src]
T: Hash,
fn hash<__HT>(&self, state: &mut __HT) where
__HT: Hasher,
[src]
__HT: Hasher,
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl<T> PartialOrd<Deserialized<T>> for Deserialized<T> where
T: PartialOrd<T>,
[src]
T: PartialOrd<T>,
fn partial_cmp(&self, other: &Deserialized<T>) -> Option<Ordering>
[src]
fn lt(&self, other: &Deserialized<T>) -> bool
[src]
fn le(&self, other: &Deserialized<T>) -> bool
[src]
fn gt(&self, other: &Deserialized<T>) -> bool
[src]
fn ge(&self, other: &Deserialized<T>) -> bool
[src]
impl<T> Eq for Deserialized<T> where
T: Eq,
[src]
T: Eq,
impl<T> Clone for Deserialized<T> where
T: Clone,
[src]
T: Clone,
fn clone(&self) -> Deserialized<T>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<T> PartialEq<Deserialized<T>> for Deserialized<T> where
T: PartialEq<T>,
[src]
T: PartialEq<T>,
fn eq(&self, other: &Deserialized<T>) -> bool
[src]
fn ne(&self, other: &Deserialized<T>) -> bool
[src]
impl<T> FromValue for Deserialized<T> where
T: DeserializeOwned,
[src]
T: DeserializeOwned,
type Intermediate = DeserializedIr<T>
fn from_value(v: Value) -> Self
[src]
Will panic if could not convert v
to Self
.
fn from_value_opt(v: Value) -> Result<Self, FromValueError>
[src]
Will return Err(Error::FromValueError(v))
if could not convert v
to Self
.
fn get_intermediate(v: Value) -> Result<Self::Intermediate, FromValueError>
[src]
Will return Err(Error::FromValueError(v))
if v
is not convertible to Self
.
impl<T> Debug for Deserialized<T> where
T: Debug,
[src]
T: Debug,
impl<T> Ord for Deserialized<T> where
T: Ord,
[src]
T: Ord,
fn cmp(&self, other: &Deserialized<T>) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
Compares and returns the minimum of two values. Read more
fn clamp(self, min: Self, max: Self) -> Self
[src]
🔬 This is a nightly-only experimental API. (
clamp
)Restrict a value to a certain interval. Read more
impl<T> Copy for Deserialized<T> where
T: Copy,
[src]
T: Copy,
impl<T> ConvIr<Deserialized<T>> for DeserializedIr<T> where
T: DeserializeOwned,
[src]
T: DeserializeOwned,
fn new(v: Value) -> Result<DeserializedIr<T>, FromValueError>
[src]
fn commit(self) -> Deserialized<T>
[src]
fn rollback(self) -> Value
[src]
Auto Trait Implementations
impl<T> Send for Deserialized<T> where
T: Send,
T: Send,
impl<T> Sync for Deserialized<T> where
T: Sync,
T: Sync,
Blanket Implementations
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T, Ir> FromRow for T where
Ir: ConvIr<T>,
T: FromValue<Intermediate = Ir>,
[src]
Ir: ConvIr<T>,
T: FromValue<Intermediate = Ir>,
fn from_row(row: Row) -> T
[src]
fn from_row_opt(row: Row) -> Result<T, FromRowError>
[src]
impl<T> Same<T> for T
type Output = T
Should always be Self