Skip to main content

DocumentMergedExt

Trait DocumentMergedExt 

Source
pub trait DocumentMergedExt {
    // Required method
    fn merged(&self) -> Option<MergedView>;
}
Expand description

Extension trait that adds merged to Document.

Required Methods§

Source

fn merged(&self) -> Option<MergedView>

Return a MergedMapping view over the document’s root mapping.

The anchor registry is built from this document automatically. Returns None if the document’s root is not a mapping.

Because the registry is owned by the returned view, this method returns an owned MergedView container rather than a borrowing MergedMapping<'_>. Use MergedView::as_mapping to obtain the borrowing view for lookups.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§