public class OntologyTreeListener extends MouseAdapter
| Modifier and Type | Field and Description |
|---|---|
protected int[] |
annotationRange
This is where we specify the start/end offsets of the highlighted
annotations which is then used for quick lookup to see if the mouse is on
one of them
|
protected ArrayList<gate.Annotation> |
highlightedAnnotations
List of highlighted annotations
|
protected Highlighter |
highlighter
Highlighter that is used for highlighting
|
| Constructor and Description |
|---|
OntologyTreeListener(OntologyTreePanel owner)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
ArrayList<gate.Annotation> |
addNewAnnotation(ClassNode node,
boolean all,
gate.FeatureMap map,
boolean isClassFeature,
boolean shouldCreateInstance)
Method to add a new annotation
|
TreePath |
getTreePath(IFolder node)
This method is to find out the path for this node from the root of the tree
|
void |
mouseClicked(MouseEvent me)
This method is invoked whenever user clicks on one of the classes in the
ontology tree
|
void |
refreshHighlights()
Method to highlight the annotations
|
void |
removeHighlights()
Method to remove all highlights
|
mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, mouseWheelMovedprotected Highlighter highlighter
protected int[] annotationRange
protected ArrayList<gate.Annotation> highlightedAnnotations
public OntologyTreeListener(OntologyTreePanel owner)
public void mouseClicked(MouseEvent me)
mouseClicked in interface MouseListenermouseClicked in class MouseAdapterpublic TreePath getTreePath(IFolder node)
node - public ArrayList<gate.Annotation> addNewAnnotation(ClassNode node, boolean all, gate.FeatureMap map, boolean isClassFeature, boolean shouldCreateInstance)
classValue - all - public void removeHighlights()
public void refreshHighlights()