Class AbstractArrowShape
java.lang.Object
org.graffiti.plugins.views.defaults.AbstractArrowShape
- All Implemented Interfaces:
Shape
,ArrowShape
- Direct Known Subclasses:
AbsoluteInhibitorArrowShape
,AbsoluteStimulationArrowShape
,AssignmentArrowShape
,CircleArrowShape
,CircleConnectArrowShape
,DiamondArrowShape
,InhibitorArrowShape
,RectangularNodeShape
,StandardArrowShape
,StandardArrowShapeLeft
,StandardArrowShapeRight
,TriggerArrowShape
public abstract class AbstractArrowShape extends Object implements ArrowShape
DOCUMENT ME!
- Version:
- $Revision: 1.10 $ $Date: 2010/12/22 13:06:19 $
- Author:
- $Author: klukas $
-
Constructor Summary
Constructors Constructor Description AbstractArrowShape()
-
Method Summary
Modifier and Type Method Description static Rectangle2D
addThickness(Rectangle2D b, double lineWidth)
Shape
affix(Point2D target, Point2D other, double lineWidth)
Sets this arrow to the target point and rotates it according to the line given by the connection between points target and other.boolean
contains(double x, double y)
DOCUMENT ME!boolean
contains(double x, double y, double w, double h)
DOCUMENT ME!boolean
contains(Point2D p)
DOCUMENT ME!boolean
contains(Rectangle2D r)
DOCUMENT ME!Point2D
getAnchor()
Returns the anchor of the arrow, i.e.Rectangle
getBounds()
DOCUMENT ME!Rectangle2D
getBounds2D()
DOCUMENT ME!PathIterator
getPathIterator(AffineTransform t)
DOCUMENT ME!PathIterator
getPathIterator(AffineTransform t, double d)
DOCUMENT ME!boolean
intersects(double x, double y, double w, double h)
DOCUMENT ME!boolean
intersects(Rectangle2D r)
DOCUMENT ME!void
updateSize(double sz)
-
Constructor Details
-
AbstractArrowShape
public AbstractArrowShape()
-
-
Method Details
-
updateSize
public void updateSize(double sz)- Specified by:
updateSize
in interfaceArrowShape
-
getAnchor
Returns the anchor of the arrow, i.e. the point where the line should be attached to the arrow. This is only valid after a call toaffix
.- Specified by:
getAnchor
in interfaceArrowShape
- Returns:
- the anchor of the arrow.
-
getBounds
DOCUMENT ME! -
getBounds2D
DOCUMENT ME!- Specified by:
getBounds2D
in interfaceShape
- Returns:
- DOCUMENT ME!
-
addThickness
-
getPathIterator
DOCUMENT ME!- Specified by:
getPathIterator
in interfaceShape
- Parameters:
t
- DOCUMENT ME!d
- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
getPathIterator
DOCUMENT ME!- Specified by:
getPathIterator
in interfaceShape
- Parameters:
t
- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
affix
Sets this arrow to the target point and rotates it according to the line given by the connection between points target and other. Ensures that the arrow is always larger than the line.- Specified by:
affix
in interfaceArrowShape
- Parameters:
target
- the point where the arrow should be put.other
- needed to calculate the direction in which the arrow should point to. The line is given by the two points target and other.lineWidth
- The total width of the line. May be used to scale the arrow so as to be larger than the line.- Returns:
- the point where the line meets the arrow
-
contains
public boolean contains(double x, double y, double w, double h)DOCUMENT ME! -
contains
public boolean contains(double x, double y)DOCUMENT ME! -
contains
DOCUMENT ME! -
contains
DOCUMENT ME! -
intersects
public boolean intersects(double x, double y, double w, double h)DOCUMENT ME!- Specified by:
intersects
in interfaceShape
- Parameters:
x
- DOCUMENT ME!y
- DOCUMENT ME!w
- DOCUMENT ME!h
- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
intersects
DOCUMENT ME!- Specified by:
intersects
in interfaceShape
- Parameters:
r
- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-