com.horstmann.violet
Class ClassRelationshipEdge

java.lang.Object
  extended by com.horstmann.violet.framework.ShapeEdge
      extended by com.horstmann.violet.framework.SegmentedLineEdge
          extended by com.horstmann.violet.ClassRelationshipEdge
All Implemented Interfaces:
Edge, java.io.Serializable, java.lang.Cloneable

public class ClassRelationshipEdge
extends SegmentedLineEdge

An edge that is shaped like a line with up to three segments with an arrowhead

See Also:
Serialized Form

Constructor Summary
ClassRelationshipEdge()
          Constructs a straight edge.
 
Method Summary
 java.lang.Object clone()
           
 void connect(Node s, Node e)
          Connect this edge to two nodes.
 BentStyle getBentStyle()
          Gets the bentStyle property
 Node getEnd()
          Gets the ending node.
 java.util.ArrayList getPoints()
          Gets the corner points of this segmented line edge
 Node getStart()
          Gets the starting node.
 void setBentStyle(BentStyle newValue)
          Sets the bentStyle property
 
Methods inherited from class com.horstmann.violet.framework.SegmentedLineEdge
draw, getBounds, getConnectionPoints, getEndArrowHead, getEndLabel, getLineStyle, getMiddleLabel, getShape, getStartArrowHead, getStartLabel, setEndArrowHead, setEndLabel, setLineStyle, setMiddleLabel, setStartArrowHead, setStartLabel
 
Methods inherited from class com.horstmann.violet.framework.ShapeEdge
contains
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClassRelationshipEdge

public ClassRelationshipEdge()
Constructs a straight edge.

Method Detail

setBentStyle

public void setBentStyle(BentStyle newValue)
Sets the bentStyle property

Parameters:
newValue - the bent style

getBentStyle

public BentStyle getBentStyle()
Gets the bentStyle property

Returns:
the bent style

getPoints

public java.util.ArrayList getPoints()
Description copied from class: SegmentedLineEdge
Gets the corner points of this segmented line edge

Specified by:
getPoints in class SegmentedLineEdge
Returns:
an array list of Point2D objects, containing the corner points

clone

public java.lang.Object clone()
Specified by:
clone in interface Edge
Overrides:
clone in class java.lang.Object

connect

public void connect(Node s,
                    Node e)
Description copied from interface: Edge
Connect this edge to two nodes.

Specified by:
connect in interface Edge
Parameters:
s - the starting node
e - the ending node

getStart

public Node getStart()
Description copied from interface: Edge
Gets the starting node.

Specified by:
getStart in interface Edge
Returns:
the starting node

getEnd

public Node getEnd()
Description copied from interface: Edge
Gets the ending node.

Specified by:
getEnd in interface Edge
Returns:
the ending node