Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Eclipse Draw2d
3.3

org.eclipse.draw2d
Class ManhattanConnectionRouter

java.lang.Object
  extended by

org.eclipse.draw2d.AbstractRouter
      extended by
org.eclipse.draw2d.ManhattanConnectionRouter
All Implemented Interfaces:
ConnectionRouter

public final class ManhattanConnectionRouter
extends AbstractRouter

Provides a Connection with an orthogonal route between the Connection's source and target anchors.


Nested Class Summary
 
Nested classes inherited from class org.eclipse.draw2d. ConnectionRouter
ConnectionRouter.NullConnectionRouter
 
Field Summary
 
Fields inherited from interface org.eclipse.draw2d. ConnectionRouter
NULL
 
Constructor Summary
ManhattanConnectionRouter ()
           
 
Method Summary
protected   Ray getDirection ( Rectangle r, Point p)
          Returns the direction the point p is in relation to the given rectangle.
protected   Ray getEndDirection ( Connection conn)
           
protected  int getRowNear ( Connection connection, int r, int n, int x)
           
protected   Ray getStartDirection ( Connection conn)
           
 void invalidate ( Connection connection)
          Causes the router to discard any cached information about the given Connection.
protected  void processPositions ( Ray start, Ray end, java.util.List positions, boolean horizontal, Connection conn)
           
 void remove ( Connection connection)
          Removes the given Connection from this routers list of Connections it is responsible for.
protected  void removeReservedLines ( Connection connection)
           
protected  void reserveColumn ( Connection connection, java.lang.Integer column)
           
protected  void reserveRow ( Connection connection, java.lang.Integer row)
           
 void route ( Connection conn)
          Routes the Connection.
 
Methods inherited from class org.eclipse.draw2d. AbstractRouter
getConstraint, getEndPoint, getStartPoint, setConstraint
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ManhattanConnectionRouter

public ManhattanConnectionRouter()
Method Detail

invalidate

public void invalidate(
Connection connection)
Description copied from class: AbstractRouter
Causes the router to discard any cached information about the given Connection.

Specified by:
invalidate in interface ConnectionRouter
Overrides:
invalidate in class AbstractRouter
Parameters:
connection - The connection to invalidate
See Also:
ConnectionRouter.invalidate(Connection)

getDirection

protected 
Ray getDirection(
Rectangle r,
                           
Point p)
Returns the direction the point p is in relation to the given rectangle. Possible values are LEFT (-1,0), RIGHT (1,0), UP (0,-1) and DOWN (0,1).

Parameters:
r - the rectangle
p - the point
Returns:
the direction from r to p

getEndDirection

protected 
Ray getEndDirection(
Connection conn)

getRowNear

protected int getRowNear(
Connection connection,
                         int r,
                         int n,
                         int x)

getStartDirection

protected 
Ray getStartDirection(
Connection conn)

processPositions

protected void processPositions(
Ray start,
                                
Ray end,
                                java.util.List positions,
                                boolean horizontal,
                                
Connection conn)

remove

public void remove(
Connection connection)
Description copied from class: AbstractRouter
Removes the given Connection from this routers list of Connections it is responsible for.

Specified by:
remove in interface ConnectionRouter
Overrides:
remove in class AbstractRouter
Parameters:
connection - The connection to remove
See Also:
ConnectionRouter.remove(Connection)

removeReservedLines

protected void removeReservedLines(
Connection connection)

reserveColumn

protected void reserveColumn(
Connection connection,
                             java.lang.Integer column)

reserveRow

protected void reserveRow(
Connection connection,
                          java.lang.Integer row)

route

public void route(
Connection conn)
Description copied from interface: ConnectionRouter
Routes the Connection.

Parameters:
conn - The Connection to route
See Also:
ConnectionRouter.route(Connection)

Eclipse Draw2d
3.3

Copyright (c) IBM Corp. and others 2000, 2007. All Rights Reserved.

 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire