documentationfor yFiles for HTML 2.6

ChannelRoutingTool

This routing algorithm applies orthogonal routes to the edges within a channel.

Inheritance Hierarchy
ChannelRoutingTool

Remarks

Each edge that should be routed has to be specified by a unique key (e.g., the edge itself) as well as two points that represent the two endpoints of this edge, see addSegment. The orthogonal route of each edge consists of three segments. More precisely, for an edge with source point (sx,sy), target point (tx,ty) and vertical channel orientation, the algorithm calculates the x-coordinate of the vertical middle segment (called mx) that can be obtained with method getChannelCoordinate after routing the edges. Hence, the actual route consists of points (sx,sy), (mx,sy), (mx,ty) and (tx,ty). Analogously, if the channel orientation is horizontal, the route consists of the points (sx,sy), (sx,my), (tx,my) and (tx,ty).

Besides the orientation, each channel is restricted by a smallest and largest assignable coordinate. If, for example, the orientation is vertical, the calculated x-coordinate of the middle segment lies between these two values. Both values can be changed by means of method setChannel.

All edges assigned to the same coordinate are said to lie in the same sub-channel. In general, the routing algorithm tries to assign coordinates such the number of sub-channels as well as the number of edge crossings is small.

Default Values of Properties

epsilon0.5
ignoreEpsilonChanneltrue

Type Details

yfiles module
layout-core
yfiles-umd modules
All layout modules, view-layout-bridge
Legacy UMD name
yfiles.router.ChannelRoutingTool
This class doesn't change the initial routes of the edges - it only calculates coordinates that can be retrieved with method getChannelCoordinate or getSubchannelRank.

Constructors

Properties

Methods