Skip to main content

ToYamlDoc

Trait ToYamlDoc 

Source
pub trait ToYamlDoc {
    // Required method
    fn apply_to_yaml_doc(&self, doc: &mut YamlDoc) -> Result<(), YamlError>;
}
Expand description

Applies a typed overlay back to a YAML document as minimal patches.

Required Methods§

Source

fn apply_to_yaml_doc(&self, doc: &mut YamlDoc) -> Result<(), YamlError>

Writes self into doc without discarding unknown fields or comments.

§Errors

Returns an error when the implementing overlay cannot be written to the document, when generated YAML is invalid, or when a queued edit conflicts with another pending edit.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§