Skip to main content

CanonicalJsonObject

Type Alias CanonicalJsonObject 

Source
pub type CanonicalJsonObject = BTreeMap<String, CanonicalJsonValue>;
Expand description

The inner type of CanonicalJsonValue::Object.

Aliased Type§

pub struct CanonicalJsonObject { /* private fields */ }

Trait Implementations§

Source§

impl CanonicalJsonObjectExt for CanonicalJsonObject

Source§

fn get_as_object( &self, field: &str, path: impl Into<String>, ) -> Result<Option<&CanonicalJsonObject>, CanonicalJsonFieldError>

Get the given field as an object. Read more
Source§

fn get_as_object_mut( &mut self, field: &str, path: impl Into<String>, ) -> Result<Option<&mut CanonicalJsonObject>, CanonicalJsonFieldError>

Get the given field as a mutable object. Read more
Source§

fn get_as_object_or_insert_default( &mut self, field: impl Into<String>, path: impl Into<String>, ) -> Result<&mut CanonicalJsonObject, CanonicalJsonFieldError>

Get the given required field as a mutable object or insert it if it is missing. Read more
Source§

fn get_as_string( &self, field: &str, path: impl Into<String>, ) -> Result<Option<&str>, CanonicalJsonFieldError>

Get the given field as a string. Read more
Source§

fn get_as_required_object( &self, field: &str, path: impl Into<String>, ) -> Result<&CanonicalJsonObject, CanonicalJsonFieldError>

Get the given required field as an object. Read more
Source§

fn get_as_required_object_mut( &mut self, field: &str, path: impl Into<String>, ) -> Result<&mut CanonicalJsonObject, CanonicalJsonFieldError>

Get the given required field as a mutable object. Read more
Source§

fn get_as_required_string( &self, field: &str, path: impl Into<String>, ) -> Result<&str, CanonicalJsonFieldError>

Get the given required field as a string. Read more
Source§

impl PartialEq<CanonicalJsonValue> for CanonicalJsonObject

Source§

fn eq(&self, other: &CanonicalJsonValue) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.