|
org.openide.text 6.9.32 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.openide.text.Annotatable
public abstract class Annotatable
Classes which are capable of holding annotations must extend this abstract class. The examples of these classes are Line or Line.Part. It allows to add/remove Annotation(s) to this class. There is also support for listening on changes of the properties like deleted or count of attached annotations.
Field Summary | |
---|---|
static String |
PROP_ANNOTATION_COUNT
Property name of the count of annotations |
static String |
PROP_DELETED
Property name for the deleted attribute |
static String |
PROP_TEXT
Property name for the content of the annotatable |
Constructor Summary | |
---|---|
Annotatable()
|
Method Summary | |
---|---|
protected void |
addAnnotation(Annotation anno)
Add annotation to this Annotatable class |
void |
addPropertyChangeListener(PropertyChangeListener l)
Add listeners on changes of annotatable properties |
protected void |
firePropertyChange(String propertyName,
Object oldValue,
Object newValue)
Fire property change to registered listeners. |
int |
getAnnotationCount()
The count of already attached annotations. |
abstract String |
getText()
Get content of the annotatable. |
boolean |
isDeleted()
Whether this Annotatable object was removed or not. |
protected void |
removeAnnotation(Annotation anno)
Remove annotation to this Annotatable class |
void |
removePropertyChangeListener(PropertyChangeListener l)
Remove listeners on changes of annotatable properties |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String PROP_ANNOTATION_COUNT
public static final String PROP_DELETED
public static final String PROP_TEXT
Constructor Detail |
---|
public Annotatable()
Method Detail |
---|
protected void addAnnotation(Annotation anno)
anno
- annotation which will be attached to this classprotected void removeAnnotation(Annotation anno)
anno
- annotation which will be detached from this classpublic final void addPropertyChangeListener(PropertyChangeListener l)
l
- change listenerpublic final void removePropertyChangeListener(PropertyChangeListener l)
l
- change listenerprotected final void firePropertyChange(String propertyName, Object oldValue, Object newValue)
public final boolean isDeleted()
public abstract String getText()
public final int getAnnotationCount()
|
org.openide.text 6.9.32 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |