pub struct MergedView { /* private fields */ }Expand description
An owning container for a MergedMapping view of a document’s root.
Holds both the root Mapping and the
AnchorRegistry built from the document, so the view can be returned
from a function without lifetime gymnastics. Call
as_mapping (or use the convenience methods
directly) to query the view.
Implementations§
Source§impl MergedView
impl MergedView
Sourcepub fn as_mapping(&self) -> MergedMapping<'_>
pub fn as_mapping(&self) -> MergedMapping<'_>
Borrow this view as a MergedMapping for lookups.
Sourcepub fn contains_key(&self, key: impl AsYaml) -> bool
pub fn contains_key(&self, key: impl AsYaml) -> bool
Check whether key is reachable through the merged view.
Sourcepub fn registry(&self) -> &AnchorRegistry
pub fn registry(&self) -> &AnchorRegistry
Return the registry built from the document.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for MergedView
impl !Send for MergedView
impl !Sync for MergedView
impl !UnwindSafe for MergedView
impl Freeze for MergedView
impl Unpin for MergedView
impl UnsafeUnpin for MergedView
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