com.mindfusion.diagramming
Class QuickRouter

java.lang.Object
  extended by com.mindfusion.diagramming.QuickRouter
All Implemented Interfaces:
LinkRouter

public class QuickRouter
extends java.lang.Object
implements LinkRouter

Implements a very fast link routing algorithm that uses a tree to represent the free and occupied regions in the diagram.


Constructor Summary
QuickRouter(Diagram diagram)
          Initializes a new instance of the QuickRouter class.
 
Method Summary
 void Resume(boolean routeDeferredLinks)
          Implements LinkRouter.Resume(boolean).
 void RouteAllLinks()
          Routes all links in the diagram.
 boolean RouteLink(DiagramLink link)
          Implements LinkRouter.RouteLink(DiagramLink).
 void RouteLinks(DiagramLinkList links)
          Implements LinkRouter.RouteLinks(DiagramLinkList).
 void Suspend()
          Implements LinkRouter.Suspend().
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QuickRouter

public QuickRouter(Diagram diagram)
Initializes a new instance of the QuickRouter class.

Parameters:
diagram -
Method Detail

RouteLink

public boolean RouteLink(DiagramLink link)
Implements LinkRouter.RouteLink(DiagramLink).

Specified by:
RouteLink in interface LinkRouter
Parameters:
link - The DiagramLink to route.
Returns:
true if a path has been found successfully, otherwise false.

RouteAllLinks

public void RouteAllLinks()
Routes all links in the diagram.


RouteLinks

public void RouteLinks(DiagramLinkList links)
Implements LinkRouter.RouteLinks(DiagramLinkList).

Specified by:
RouteLinks in interface LinkRouter
Parameters:
links - A list of DiagramLink objects that should be routed.

Suspend

public void Suspend()
Implements LinkRouter.Suspend().

Specified by:
Suspend in interface LinkRouter

Resume

public void Resume(boolean routeDeferredLinks)
Implements LinkRouter.Resume(boolean).

Specified by:
Resume in interface LinkRouter
Parameters:
routeDeferredLinks - true if the links should be routed, otherwise false.