Package diva.canvas.tutorial
Class ArcTutorial.SelfPTarget
- java.lang.Object
-
- diva.canvas.connector.AbstractConnectorTarget
-
- diva.canvas.connector.PerimeterTarget
-
- diva.canvas.tutorial.ArcTutorial.SelfPTarget
-
- All Implemented Interfaces:
ConnectorTarget
- Enclosing class:
- ArcTutorial
public static class ArcTutorial.SelfPTarget extends PerimeterTarget
SelfPTarget is used to find target sites. It overrides PerimeterSite, but allows connector head and tails to be located on the same figure.
-
-
Constructor Summary
Constructors Constructor Description SelfPTarget()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
acceptHead(Connector c, Figure f)
Return true.boolean
acceptTail(Connector c, Figure f)
Return true.-
Methods inherited from class diva.canvas.connector.PerimeterTarget
getHeadSite
-
Methods inherited from class diva.canvas.connector.AbstractConnectorTarget
getHeadSite, getHeadSite, getHeadSite, getTailSite, getTailSite, getTailSite, getTailSite
-
-
-
-
Method Detail
-
acceptHead
public boolean acceptHead(Connector c, Figure f)
Return true. This allows "self-arcs"- Overrides:
acceptHead
in classAbstractConnectorTarget
- Parameters:
c
- The connectorf
- The figure- Returns:
- true if the tail of the connector can be connected to the figure
-
acceptTail
public boolean acceptTail(Connector c, Figure f)
Return true. This allows "self-arcs"- Overrides:
acceptTail
in classAbstractConnectorTarget
- Parameters:
c
- The connectorf
- The figure- Returns:
- true if the head of the connector can be connected to the figure
-
-