pub enum ValueType {
Primitive(PrimitiveValue),
Array(Vec<ValuePrimitiveType>),
Nested(Value),
}
Expand description
Supports primitive types string
, number
, boolean
, null
May be an array of those types, or an object of those types
Object keys are always strings, values can be any basic type, an array, or a nested object.
Array values must all be the same type.
Variants§
Primitive(PrimitiveValue)
A primitive value
Array(Vec<ValuePrimitiveType>)
An array of values
Nested(Value)
A nested object
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ValueType
impl<'de> Deserialize<'de> for ValueType
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for ValueType
Auto Trait Implementations§
impl Freeze for ValueType
impl RefUnwindSafe for ValueType
impl Send for ValueType
impl Sync for ValueType
impl Unpin for ValueType
impl UnwindSafe for ValueType
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more