pub struct JsonContent { /* private fields */ }Expand description
JSON configuration content.
This type provides CRUD operations for JSON configuration data.
Implementations§
Source§impl JsonContent
impl JsonContent
Sourcepub fn from_value(value: JsonValue) -> Self
pub fn from_value(value: JsonValue) -> Self
Creates a new JsonContent from a serde_json::Value.
Sourcepub fn into_value(self) -> JsonValue
pub fn into_value(self) -> JsonValue
Converts to the underlying serde_json::Value.
Trait Implementations§
Source§impl Clone for JsonContent
impl Clone for JsonContent
Source§fn clone(&self) -> JsonContent
fn clone(&self) -> JsonContent
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl ConfigContent for JsonContent
impl ConfigContent for JsonContent
Source§fn insert(&mut self, key: &Key, value: &Value) -> ConfigResult<()>
fn insert(&mut self, key: &Key, value: &Value) -> ConfigResult<()>
Insert a new value at the specified key path. Read more
Source§fn update(&mut self, key: &Key, value: &Value) -> ConfigResult<()>
fn update(&mut self, key: &Key, value: &Value) -> ConfigResult<()>
Update an existing value at the specified key path. Read more
Source§fn delete(&mut self, key: &Key) -> ConfigResult<()>
fn delete(&mut self, key: &Key) -> ConfigResult<()>
Delete a value at the specified key path. Read more
Source§fn upsert(&mut self, key: &Key, value: &Value) -> ConfigResult<()>
fn upsert(&mut self, key: &Key, value: &Value) -> ConfigResult<()>
Upsert (insert or update) a value at the specified key path. Read more
Source§fn contains_key(&self, key: &Key) -> bool
fn contains_key(&self, key: &Key) -> bool
Check if a key exists.
Source§impl Debug for JsonContent
impl Debug for JsonContent
Source§impl Display for JsonContent
impl Display for JsonContent
Source§impl FromStr for JsonContent
impl FromStr for JsonContent
Source§impl PartialEq for JsonContent
impl PartialEq for JsonContent
impl StructuralPartialEq for JsonContent
Auto Trait Implementations§
impl Freeze for JsonContent
impl RefUnwindSafe for JsonContent
impl Send for JsonContent
impl Sync for JsonContent
impl Unpin for JsonContent
impl UnsafeUnpin for JsonContent
impl UnwindSafe for JsonContent
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