Package diva.canvas.tutorial
Class ConnectorTutorial.SRTarget
- java.lang.Object
-
- diva.canvas.connector.AbstractConnectorTarget
-
- diva.canvas.tutorial.ConnectorTutorial.SRTarget
-
- All Implemented Interfaces:
ConnectorTarget
- Enclosing class:
- ConnectorTutorial
public static class ConnectorTutorial.SRTarget extends AbstractConnectorTarget
SRTarget is used to find a useful site on a SitedRectangle.
-
-
Constructor Summary
Constructors Constructor Description SRTarget()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Site
getHeadSite(Figure f, double x, double y)
Return the nearest site on the figure-
Methods inherited from class diva.canvas.connector.AbstractConnectorTarget
acceptHead, acceptTail, getHeadSite, getHeadSite, getHeadSite, getTailSite, getTailSite, getTailSite, getTailSite
-
-
-
-
Method Detail
-
getHeadSite
public Site getHeadSite(Figure f, double x, double y)
Return the nearest site on the figure- Specified by:
getHeadSite
in interfaceConnectorTarget
- Specified by:
getHeadSite
in classAbstractConnectorTarget
- Parameters:
f
- The figurex
- The x location of the sitey
- The y location of the site- Returns:
- The head site
-
-