pub struct AnnotationMap { /* private fields */ }Expand description
Collection of annotations indexed by path
Implementations§
Source§impl AnnotationMap
impl AnnotationMap
Sourcepub fn get(&self, path: &str) -> Option<&Annotation>
pub fn get(&self, path: &str) -> Option<&Annotation>
Get an annotation by path
Sourcepub fn insert(&mut self, annotation: Annotation)
pub fn insert(&mut self, annotation: Annotation)
Insert an annotation
Sourcepub fn iter(&self) -> impl Iterator<Item = (&String, &Annotation)>
pub fn iter(&self) -> impl Iterator<Item = (&String, &Annotation)>
Iterate over all annotations
Trait Implementations§
Source§impl Clone for AnnotationMap
impl Clone for AnnotationMap
Source§fn clone(&self) -> AnnotationMap
fn clone(&self) -> AnnotationMap
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AnnotationMap
impl Debug for AnnotationMap
Source§impl Default for AnnotationMap
impl Default for AnnotationMap
Source§fn default() -> AnnotationMap
fn default() -> AnnotationMap
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for AnnotationMap
impl RefUnwindSafe for AnnotationMap
impl Send for AnnotationMap
impl Sync for AnnotationMap
impl Unpin for AnnotationMap
impl UnwindSafe for AnnotationMap
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)