Add Annotateable::remove_annotation*()

This commit is contained in:
Matthias Beyer 2016-10-13 16:11:10 +02:00
parent 3f5aded446
commit 91d1c61518

View file

@ -49,6 +49,13 @@ pub trait Annotateable {
/// This lists only annotations that are generated via the `DefaultAnnotationPathGenerator` /// This lists only annotations that are generated via the `DefaultAnnotationPathGenerator`
fn annotations(&self) -> Result<Vec<StoreId>>; fn annotations(&self) -> Result<Vec<StoreId>>;
/// Remove an annotation by its ID
fn remove_annotation(&mut self, ann_id: &str) -> Result<()>;
/// Remove an annotation and remove the annotation object from the store, if there's no more
/// link to it.
fn remove_annotation_with_gc(&mut self, ann_id: &str, store: &Store) -> Result<()>;
} }
/// A AnnotationPathGenerator generates a unique path for the annotation to be generated. /// A AnnotationPathGenerator generates a unique path for the annotation to be generated.
@ -105,4 +112,15 @@ impl Annotateable for FileLockEntry {
) )
} }
/// Remove an annotation by its ID
fn remove_annotation(&mut self, ann_id: &str) -> Result<()> {
unimplemented!()
}
/// Remove an annotation and remove the annotation object from the store, if there's no more
/// link to it.
fn remove_annotation_with_gc(&mut self, ann_id: &str, store: &Store) -> Result<()> {
unimplemented!()
}
} }