nondestructive
Nondestructive editing tries to preserve as much as possible of the existing structure, while allowing the document to be modified in place.
This project is as of yet, incomplete!
See the corresponding module for detailed documentation on how to use:
Examples
use Context;
use yaml;
let mut doc = from_slice?;
let mapping = doc.root.as_mapping.context?;
let name = mapping.get.context?;
assert_eq!;
let mut mapping = doc.root_mut.into_mapping_mut.context?;
let mut name = mapping.get_mut.context?;
name.set_string;
let mut country = mapping.get_mut.context?;
country.set_string;
assert_eq!;