jts
Class EgenhoferInteractor

java.lang.Object
  extended by interactors.Interactor
      extended by jts.EgenhoferInteractor

public class EgenhoferInteractor
extends Interactor

Class for displaying the Egenhofer 9IM relation between two polygons.


Field Summary
 
Fields inherited from class interactors.Interactor
handler
 
Constructor Summary
EgenhoferInteractor(InteractionHandler handler)
          Constructs the Egenhofer interactor.
 
Method Summary
 void draw(GL gl, GLU glu, GLUT glut)
          Draws a line from the selected object to the mouse.
 java.awt.Cursor getCursor()
          Gets the crosshair cursor.
 void getEgenhoferRelation(OntologyObject object1, OntologyObject object2)
          Displays a dialog showing the Egenhofer relation between the specified objects.
 void mousePressed(java.awt.event.MouseEvent arg0)
          Left click selects an object if no object is selected.
 
Methods inherited from class interactors.Interactor
endInteraction, keyPressed, keyReleased, mouseDragged, mouseMoved, mouseReleased, startInteraction
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EgenhoferInteractor

public EgenhoferInteractor(InteractionHandler handler)
Constructs the Egenhofer interactor.

Parameters:
handler - - the interaction handler
Method Detail

draw

public void draw(GL gl,
                 GLU glu,
                 GLUT glut)
Draws a line from the selected object to the mouse.

Overrides:
draw in class Interactor

getCursor

public java.awt.Cursor getCursor()
Gets the crosshair cursor.

Overrides:
getCursor in class Interactor

mousePressed

public void mousePressed(java.awt.event.MouseEvent arg0)
Left click selects an object if no object is selected. If an object is currently selected, then left click get the Egenhofer relation between the previously selected object and the newly selected object. Right click deselects the current object or ends the interaction if no object is selected.

Overrides:
mousePressed in class Interactor

getEgenhoferRelation

public void getEgenhoferRelation(OntologyObject object1,
                                 OntologyObject object2)
Displays a dialog showing the Egenhofer relation between the specified objects.

Parameters:
object1 - - the first object
object2 - - the second object