Enum adventjson::JsonObject [−][src]
pub enum JsonObject { Array(Vec<Self>), Obj(Vec<(String, Self)>), Number(f64), JsonStr(String), Bool(bool), Null, }
Expand description
Variants
Array(Vec<Self>)
An array of objects (e.g.: [1,2,3])
Key-value pairs (e.g.: {"first": 10, "other": 15})
Number(f64)
A number (e.g.: -0.08333)
JsonStr(String)
A string (e.g.: "Test: \"")
Bool(bool)
A boolean (e.g. true)
The null-value
Implementations
impl JsonObject
[src]
impl JsonObject
[src]Trait Implementations
impl Clone for JsonObject
[src]
impl Clone for JsonObject
[src]fn clone(&self) -> JsonObject
[src]
fn clone(&self) -> JsonObject
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
impl Debug for JsonObject
[src]
impl Debug for JsonObject
[src]impl Default for JsonObject
[src]
impl Default for JsonObject
[src]fn default() -> Self
[src]
fn default() -> Self
[src]The default value is JsonObject::Null
impl Display for JsonObject
[src]
impl Display for JsonObject
[src]impl Ord for JsonObject
[src]
impl Ord for JsonObject
[src]Save because no not-number values are allowed in json
impl PartialEq<JsonObject> for JsonObject
[src]
impl PartialEq<JsonObject> for JsonObject
[src]fn eq(&self, other: &JsonObject) -> bool
[src]
fn eq(&self, other: &JsonObject) -> bool
[src]This method tests for self
and other
values to be equal, and is used
by ==
. Read more
fn ne(&self, other: &JsonObject) -> bool
[src]
fn ne(&self, other: &JsonObject) -> bool
[src]This method tests for !=
.
impl PartialOrd<JsonObject> for JsonObject
[src]
impl PartialOrd<JsonObject> for JsonObject
[src]fn partial_cmp(&self, other: &JsonObject) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &JsonObject) -> Option<Ordering>
[src]This method returns an ordering between self
and other
values if one exists. Read more
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl Eq for JsonObject
[src]
Save because no not-number values are allowed in json
impl StructuralPartialEq for JsonObject
[src]
Auto Trait Implementations
impl RefUnwindSafe for JsonObject
impl Send for JsonObject
impl Sync for JsonObject
impl Unpin for JsonObject
impl UnwindSafe for JsonObject
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more