|
Eclipse Platform Release 3.2 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IAnnotationModelExtension
Extends IAnnotationModel
with the
ability piggyback other annotation models. It also introduces the concept of
modification time stamps and adds methods for richer manipulation methods.
Method Summary | |
---|---|
void |
addAnnotationModel(java.lang.Object key,
IAnnotationModel attachment)
Attaches attachment to the receiver. |
IAnnotationModel |
getAnnotationModel(java.lang.Object key)
Returns the attached IAnnotationModel for key ,
or null if none is attached for key . |
java.lang.Object |
getModificationStamp()
Returns the modification stamp of this annotation model. |
void |
modifyAnnotationPosition(Annotation annotation,
Position position)
Modifies the position associated with the given annotation to equal the given position. |
void |
removeAllAnnotations()
Removes all annotations from this annotation model. |
IAnnotationModel |
removeAnnotationModel(java.lang.Object key)
Removes and returns the attached IAnnotationModel for
key . |
void |
replaceAnnotations(Annotation[] annotationsToRemove,
java.util.Map annotationsToAdd)
Adds and removes annotations to/from this annotation model in a single step. |
Method Detail |
---|
void addAnnotationModel(java.lang.Object key, IAnnotationModel attachment)
attachment
to the receiver. Connects
attachment
to the currently connected document. If
attachment
is already attached (even) under a different
key), it is not attached again.
key
- the key through which the attachment is identified.attachment
- the attached IAnnotationModel
IAnnotationModel getAnnotationModel(java.lang.Object key)
IAnnotationModel
for key
,
or null
if none is attached for key
.
key
- the key through which the attachment is identified.
IAnnotationModel
attached under
key
, or null
IAnnotationModel removeAnnotationModel(java.lang.Object key)
IAnnotationModel
for
key
.
key
- the key through which the attachment is identified.
IAnnotationModel
attached under
key
, or null
void replaceAnnotations(Annotation[] annotationsToRemove, java.util.Map annotationsToAdd) throws java.lang.ClassCastException
annotationsToRemove
- the annotations to be removed, may be
null
annotationsToAdd
- the annotations which will be added, may be
null
each map entry has an
Annotation
as key and a Position
as value
java.lang.ClassCastException
- if one of the map key or values has a wrong
typevoid modifyAnnotationPosition(Annotation annotation, Position position)
null
the annotation is removed from the model. All
annotation model change listeners will be informed about the change.
annotation
- the annotation whose associated position should be
modifiedposition
- the position to whose values the associated position
should be changedvoid removeAllAnnotations()
java.lang.Object getModificationStamp()
|
Eclipse Platform Release 3.2 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp. and others 2000, 2006. All rights reserved.