This interface defines the model for managing annotations attached to a document. The model maintains a set of annotations for a given document and notifies registered annotation model listeners about annotation model changes. It also provides methods for querying the current position of an annotation managed by this model.
In order to provide backward compatibility for clients of IAnnotationModel
, extension interfaces are used to provide a means of evolution. The following extension interfaces exist:
- {@link org.eclipse.jface.text.source.IAnnotationModelExtension} since version 3.0 introducing the conceptof model piggybacking annotation models, modification time stamps, and enhanced manipulation methods.
- {@link org.eclipse.jface.text.source.IAnnotationModelExtension2} since version 3.4 allows to retrieveannotations within a given region.
Clients may implement this interface or use the default implementation provided by
AnnotationModel
.
@see org.eclipse.jface.text.source.IAnnotationModelExtension
@see org.eclipse.jface.text.source.IAnnotationModelExtension2
@see org.eclipse.jface.text.source.Annotation
@see org.eclipse.jface.text.source.IAnnotationModelListener