CH.ifa.draw.figures
Class ShortestDistanceConnector

java.lang.Object
  extended by CH.ifa.draw.standard.AbstractConnector
      extended by CH.ifa.draw.figures.ShortestDistanceConnector
All Implemented Interfaces:
Connector, Storable, java.io.Serializable

public class ShortestDistanceConnector
extends AbstractConnector

A ShortestDistance locates connection points by finding the shortest distance between the start and end of the connection. It doesn't connect to the ares defined by Figure.connectionInsets()

See Also:
Figure.connectionInsets(), Connector, Serialized Form

Constructor Summary
ShortestDistanceConnector()
           
ShortestDistanceConnector(Figure owner)
           
 
Method Summary
 java.awt.Point findEnd(ConnectionFigure connection)
          Finds the end point for the connection.
protected  java.awt.Point findPoint(ConnectionFigure connection, boolean getStart)
           
 java.awt.Point findStart(ConnectionFigure connection)
          Finds the start point for the connection.
 
Methods inherited from class CH.ifa.draw.standard.AbstractConnector
containsPoint, displayBox, draw, findPoint, owner, read, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ShortestDistanceConnector

public ShortestDistanceConnector()

ShortestDistanceConnector

public ShortestDistanceConnector(Figure owner)
Method Detail

findStart

public java.awt.Point findStart(ConnectionFigure connection)
Description copied from interface: Connector
Finds the start point for the connection.

Specified by:
findStart in interface Connector
Overrides:
findStart in class AbstractConnector

findEnd

public java.awt.Point findEnd(ConnectionFigure connection)
Description copied from interface: Connector
Finds the end point for the connection.

Specified by:
findEnd in interface Connector
Overrides:
findEnd in class AbstractConnector

findPoint

protected java.awt.Point findPoint(ConnectionFigure connection,
                                   boolean getStart)