pub struct Archive {
pub paths: BTreeMap<CompactString, Archive>,
pub values: BTreeMap<CompactString, Value>,
}Fields§
§paths: BTreeMap<CompactString, Archive>Every ‘~’ prefixed keys
values: BTreeMap<CompactString, Value>All elements except child path nodes.
Implementations§
source§impl Archive
impl Archive
pub fn find_path<'s, 'a>( &'s self, path: impl IntoIterator<Item = &'a str> ) -> Option<&'s Archive>
pub fn find_or_create_path_mut<'s, 'a>( &'s mut self, path: impl IntoIterator<Item = &'a str> ) -> &'s mut Archive
sourcepub fn create_patch(&self, newer: &mut Self) -> Self
pub fn create_patch(&self, newer: &mut Self) -> Self
Creates archive which contains only the differences between two archives. This does not affect to removed categories/values of newer archive.
Patched elements are removed from newer archive.
pub fn is_empty(&self) -> bool
pub fn merge_onto(&mut self, other: Self)
pub fn merge(self, other: Self) -> Self
Trait Implementations§
source§impl<'a> Deserialize<'a> for Archive
impl<'a> Deserialize<'a> for Archive
source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'a>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where D: Deserializer<'a>,
Deserialize this value from the given Serde deserializer. Read more