Enum kserde::Thing [−][src]
A flexible data structure that everything can deserialize to.
Variants
Bool(bool)
Number(f64)
Object(HashMap<Cow<'a, str>, ObjectProperty<'a>>)
Implementations
impl<'a> Thing<'a>
[src]
pub fn string(&self) -> Option<&Cow<'a, str>>
[src]
pub fn bool(&self) -> Option<bool>
[src]
pub fn number(&self) -> Option<f64>
[src]
pub fn object(&self) -> Option<&HashMap<Cow<'a, str>, ObjectProperty<'a>>>
[src]
pub fn array(&self) -> Option<&Vec<Thing<'a>>>
[src]
impl<'a> Thing<'a>
[src]
Trait Implementations
impl<'a> Debug for Thing<'a>
[src]
impl<'a> Deserialize<'a> for Thing<'a>
[src]
fn deserialize<D: Deserializer<'a>>(deserializer: &mut D) -> Option<Self>
[src]
impl<'a> Serialize for Thing<'a>
[src]
fn serialize<S: Serializer>(&self, serializer: &mut S)
[src]
Auto Trait Implementations
impl<'a> RefUnwindSafe for Thing<'a>
impl<'a> Send for Thing<'a>
impl<'a> Sync for Thing<'a>
impl<'a> Unpin for Thing<'a>
impl<'a> UnwindSafe for Thing<'a>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
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.
pub 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>,