Package | com.yworks.yfiles.layout.router.polyline |
Class | public class EdgeRouter |
Inheritance | EdgeRouter AbstractLayoutStage YObject Object |
Edges can be routed orthogonally, i.e. only horizontal and vertical segments, or with additional segments with other slopes. Polyline routing can be activated using polylineRouting.
In both routing styles, edges can be grouped so they share common segments in the beginning or end of their routes. Edges are marked as grouped by using the data provider keys com.yworks.yfiles.layout.PortConstraintKeys.SOURCE_GROUPID_KEY (for source grouped edges) or com.yworks.yfiles.layout.PortConstraintKeys.TARGET_GROUPID_KEY (for target grouped edges).
Many settings of the edge layout can be controlled individually for every edge using com.yworks.yfiles.layout.router.polyline.EdgeLayoutDescriptor instances. So, if at the time of the invocation a com.yworks.yfiles.base.DataProvider instance is bound to the graph using the EDGE_LAYOUT_DESCRIPTOR_DPKEY key, the EdgeLayoutDescriptor
s provided for the individual edges are used. Whenever no descriptor is provided for an edge, a default edge layout descriptor is used as fall-back value. This edge layout descriptor can be obtained with defaultEdgeLayoutDescriptor.
EdgeRouter supports two approaches to connect edges on a specific side or even an exact location to a node. com.yworks.yfiles.layout.PortConstraint s define a single constraint for the ports of an edge. To realize more complex port restrictions, several com.yworks.yfiles.layout.PortCandidate s or com.yworks.yfiles.layout.PortCandidateSet s can be assigned to edges or nodes. If an edge with registered PortCandidate
s connects to nodes with PortCandidateSet
s, the layouter will try to match both collections to find an appropriate port. In case there is no matching port candidate, a PortCandidate
specified for the edge is preferred. Since their simultaneous existence at the same node may be ambiguous, it is not recommended to use a combination of PortConstraint
s and PortCandidate
s in the same layout.
com.yworks.yfiles.layout.router.polyline.EdgeRouter coordinates all settings and steps that are needed to achieve a polylinear or orthogonal edge routing. There are three steps that are executed in the following order:
Partition
(see: com.yworks.yfiles.layout.router.polyline.PathSearch, com.yworks.yfiles.layout.router.polyline.Path). PathSearch
will consider. They also can add some information to PartitionCells
that, for example, specifies whether or not the PartitionCell
belongs to a node. PathSearchExtension (com.yworks.yfiles.layout.router.polyline.PathSearchExtension) s influence the PathSearch
by adding costs for traversing specified PartitionCells
or narrowing their intervals to allow a less expensive traversal of a PartitionCell
. For example, the PathSearch
adds costs to a PartitionCell
that was marked as an obstacle that belongs to a node, so the edge will avoid the node.
See also
Property | Defined By | ||
---|---|---|---|
considerEdgeLabelsEnabled : Boolean
Determines whether or not this edge router considers labels of edges that are not in the edge (sub-)set to be routed (see sphereOfAction. | EdgeRouter | ||
considerNodeLabelsEnabled : Boolean
Determines whether or not this edge router considers node labels as obstacles for edge routes. | EdgeRouter | ||
coreLayouter : Layouter
Specifies the core layouter. | AbstractLayoutStage | ||
defaultEdgeLayoutDescriptor : EdgeLayoutDescriptor [read-only]
Returns the com.yworks.yfiles.layout.router.polyline.EdgeLayoutDescriptor instance used for all those edges, that do not have a specific layout descriptor assigned. | EdgeRouter | ||
edgeOrderComparator : Comparator
Specifies the custom java.util.Comparator used to sort the edges of the graph to determine the processing order of the edges. | EdgeRouter | ||
grid : Grid
Getter:
Returns the com.yworks.yfiles.layout.router.polyline.Grid the edge router tries to place the orthogonal segments on. | EdgeRouter | ||
ignoreInnerNodeLabelsEnabled : Boolean
Determines whether or not this edge router ignores node labels that are inside the bounds of their owner as obstacles for edge routes. | EdgeRouter | ||
maximumDuration : LongImpl
Getter:
Returns the time limit (in milliseconds) set for the layout algorithm. | EdgeRouter | ||
maximumPolylineSegmentRatio : Number
Specifies the maximum segment length ratio at each end of an orthogonal segment that may get converted into a (non-orthogonal) polyline segment. | EdgeRouter | ||
minimalNodeToEdgeDistance : Number
Determines the minimal distance between edges and node bounds. | EdgeRouter | ||
partition : GraphPartition [read-only]
Returns the com.yworks.yfiles.layout.router.polyline.GraphPartition used during the layout. | EdgeRouter | ||
polylineRouting : Boolean
Determines whether or not this edge router creates (non-orthogonal) polyline segments. | EdgeRouter | ||
preferredPolylineSegmentLength : Number
Specifies the preferred length of (non-orthogonal) polyline segments. | EdgeRouter | ||
registeredPartitionExtensions : List [read-only]
Returns a list containing all registered com.yworks.yfiles.layout.router.polyline.GraphPartitionExtension s. | EdgeRouter | ||
registeredPathSearchExtensions : List [read-only]
Returns a list containing all registered com.yworks.yfiles.layout.router.polyline.PathSearchExtension s. | EdgeRouter | ||
rerouting : Boolean
Determines whether or not the edge router uses an additional step to reroute those edges that are considered to have the worst paths. | EdgeRouter | ||
selectedEdgesDpKey : Object
Specifies the data provider key used to look up the selected state of the edges of the graph to be laid out. | EdgeRouter | ||
selectedNodesDpKey : Object
Specifies the data provider key used to look up the selected state of the nodes of the graph to be laid out. | EdgeRouter | ||
sphereOfAction : int
Getter:
Returns the currently set sphere of action specifier. | EdgeRouter |
Method | Defined By | ||
---|---|---|---|
EdgeRouter(init:Boolean = true)
Creates a new EdgeRouter instance. | EdgeRouter | ||
canLayout(graph:LayoutGraph):Boolean [override] | EdgeRouter | ||
doLayout(graph:LayoutGraph):void [override] | EdgeRouter | ||
equals(o:Object):Boolean | YObject | ||
getClass():Class [override] | EdgeRouter | ||
hashCode():int | YObject | ||
[static]
Creates a new EdgeRouter instance. | EdgeRouter | ||
[static]
Creates a new EdgeRouter instance with the given core Layouter. | EdgeRouter |
Method | Defined By | ||
---|---|---|---|
canLayoutCore(graph:LayoutGraph):Boolean
Queries the core layouter whether or not the given graph can be laid out. | AbstractLayoutStage | ||
checkGroupNodeSize(layout:GraphLayout, node:Object):void
This method throws an com.yworks.bridge.util.IllegalArgumentException if the width/height of the given group node object is zero. | EdgeRouter | ||
checkNodeSize(layout:GraphLayout, node:Object):void
This method throws an com.yworks.bridge.util.IllegalArgumentException if the width/height of the given node object is zero. | EdgeRouter | ||
cleanupGraphPartition(partition:GraphPartition):void
Cleans up the given com.yworks.yfiles.layout.router.polyline.GraphPartition. | EdgeRouter | ||
configureGraphPartition(partition:GraphPartition):void
Configures the given com.yworks.yfiles.layout.router.polyline.GraphPartition. | EdgeRouter | ||
configurePathSearch(pathSearch:PathSearch):void
Configures the given com.yworks.yfiles.layout.router.polyline.PathSearch. | EdgeRouter | ||
Creates the com.yworks.yfiles.layout.router.polyline.PathSearchConfiguration that is used during the path search. | EdgeRouter | ||
createDefaultEdgeOrderComparator(graph:LayoutGraph, configuration:PathSearchConfiguration):Comparator
Creates and returns the default java.util.Comparator used to determine the order the edges of the graph are laid out with. | EdgeRouter | ||
Creates a com.yworks.yfiles.layout.router.polyline.GraphPartition that divides the area of the graph into several rectangles. | EdgeRouter | ||
Creates a com.yworks.yfiles.layout.router.polyline.DynamicObstacleDecomposition that is used by the com.yworks.yfiles.layout.router.polyline.GraphPartition to divide the graph area in rectangles. | EdgeRouter | ||
Creates a com.yworks.yfiles.layout.router.polyline.ChannelBasedPathRouting that routes the edges using pre-calculated com.yworks.yfiles.layout.router.polyline.Path objects. | EdgeRouter | ||
Creates a com.yworks.yfiles.layout.router.polyline.PathSearch that finds the edges' paths through the com.yworks.yfiles.layout.router.polyline.GraphPartition. | EdgeRouter | ||
createPathSearchContext(pathSearch:PathSearch, configuration:PathSearchConfiguration):PathSearchContext
Creates a com.yworks.yfiles.layout.router.polyline.PathSearchContext that provides context information for the path search algorithm. | EdgeRouter | ||
doLayoutCore(graph:LayoutGraph):void
Invokes the layout routine of the core layouter. | AbstractLayoutStage | ||
Returns the com.yworks.yfiles.layout.router.polyline.EdgeLayoutDescriptor provided by the com.yworks.yfiles.base.DataProvider with the key EDGE_LAYOUT_DESCRIPTOR_DPKEY for the given edge. | EdgeRouter | ||
initAbstractLayoutStage1():void | AbstractLayoutStage | ||
initAbstractLayoutStage2(core:Layouter):void | AbstractLayoutStage | ||
initEdgeRouter1():void
Initializes this object. | EdgeRouter | ||
initEdgeRouter2(core:Layouter):void
Initializes this object. | EdgeRouter | ||
Utility method that returns the selection state of the given edge. | EdgeRouter |
Constant | Defined By | ||
---|---|---|---|
EDGE_LAYOUT_DESCRIPTOR_DPKEY : String = y.layout.router.polyline.EdgeRouter.EDGE_LAYOUT_DESCRIPTOR_DPKEY [static]
com.yworks.yfiles.base.DataProvider key used to store the com.yworks.yfiles.layout.router.polyline.EdgeLayoutDescriptor for each edge. | EdgeRouter | ||
LABEL_CROSSING_COST_FACTOR_DPKEY : String = y.layout.router.polyline.EdgeRouter.LABEL_CROSSING_COST_FACTOR_DPKEY [static]
com.yworks.yfiles.base.DataProvider key used to store a cost factor for each label. | EdgeRouter | ||
ROUTE_ALL_EDGES : int = 0 [static]
Sphere of action specifier. | EdgeRouter | ||
ROUTE_EDGES_AT_SELECTED_NODES : int = 4 [static]
Sphere of action specifier. | EdgeRouter | ||
ROUTE_SELECTED_EDGES : int = 2 [static]
Sphere of action specifier. | EdgeRouter |
considerEdgeLabelsEnabled | property |
considerEdgeLabelsEnabled:Boolean
Determines whether or not this edge router considers labels of edges that are not in the edge (sub-)set to be routed (see sphereOfAction.
By default edge labels are not considered.
public function get considerEdgeLabelsEnabled():Boolean
public function set considerEdgeLabelsEnabled(value:Boolean):void
See also
considerNodeLabelsEnabled | property |
considerNodeLabelsEnabled:Boolean
Determines whether or not this edge router considers node labels as obstacles for edge routes.
By default node labels are not considered.
public function get considerNodeLabelsEnabled():Boolean
public function set considerNodeLabelsEnabled(value:Boolean):void
See also
defaultEdgeLayoutDescriptor | property |
defaultEdgeLayoutDescriptor:EdgeLayoutDescriptor
[read-only] Returns the com.yworks.yfiles.layout.router.polyline.EdgeLayoutDescriptor instance used for all those edges, that do not have a specific layout descriptor assigned.
public function get defaultEdgeLayoutDescriptor():EdgeLayoutDescriptor
See also
edgeOrderComparator | property |
edgeOrderComparator:Comparator
Specifies the custom java.util.Comparator used to sort the edges of the graph to determine the processing order of the edges.
The processing order may influence the quality of the individual edge paths. When routing an edge, only the paths of already routed edges and fixed edges (that are not routed at all) can be considered. Therefore earlier edges have to consider less other edge paths then later edges which might have to use less optimal alternative paths.
The default is null
and the comparator returned by createDefaultEdgeOrderComparator() is used.
public function get edgeOrderComparator():Comparator
public function set edgeOrderComparator(value:Comparator):void
See also
grid | property |
grid:Grid
Getter: Returns the com.yworks.yfiles.layout.router.polyline.Grid the edge router tries to place the orthogonal segments on.
By default no grid is specified, so null
will be returned.
public function get grid():Grid
public function set grid(value:Grid):void
See also
ignoreInnerNodeLabelsEnabled | property |
ignoreInnerNodeLabelsEnabled:Boolean
Determines whether or not this edge router ignores node labels that are inside the bounds of their owner as obstacles for edge routes.
This setting has only an effect if node labels shall be considered (considerNodeLabelsEnabled) at all and is especially useful to ignore inner node labels of group nodes.
Per default, this option is disabled.
public function get ignoreInnerNodeLabelsEnabled():Boolean
public function set ignoreInnerNodeLabelsEnabled(value:Boolean):void
See also
maximumDuration | property |
maximumDuration:LongImpl
Getter: Returns the time limit (in milliseconds) set for the layout algorithm.
By default no time limit is set.
Setter: Sets a preferred time limit (>= 0 and in milliseconds) for the layout algorithm.Note that restricting the maximum duration may result in a worse layout quality. Furthermore, the actual runtime may exceed the maximum duration since the layout algorithm still has to find a valid solution.
By default no time limit is set.
public function get maximumDuration():LongImpl
public function set maximumDuration(value:LongImpl):void
maximumPolylineSegmentRatio | property |
maximumPolylineSegmentRatio:Number
Specifies the maximum segment length ratio at each end of an orthogonal segment that may get converted into a (non-orthogonal) polyline segment.
By default the maximum ratio for polyline segments is 0.3.
public function get maximumPolylineSegmentRatio():Number
public function set maximumPolylineSegmentRatio(value:Number):void
minimalNodeToEdgeDistance | property |
minimalNodeToEdgeDistance:Number
Determines the minimal distance between edges and node bounds.
By default the minimal node to edge distance is 10.
public function get minimalNodeToEdgeDistance():Number
public function set minimalNodeToEdgeDistance(value:Number):void
See also
partition | property |
partition:GraphPartition
[read-only] Returns the com.yworks.yfiles.layout.router.polyline.GraphPartition used during the layout.
public function get partition():GraphPartition
See also
polylineRouting | property |
polylineRouting:Boolean
Determines whether or not this edge router creates (non-orthogonal) polyline segments.
By default polyline edge routing is disabled.
public function get polylineRouting():Boolean
public function set polylineRouting(value:Boolean):void
See also
preferredPolylineSegmentLength | property |
preferredPolylineSegmentLength:Number
Specifies the preferred length of (non-orthogonal) polyline segments.
Note that this restriction isn't used for orthogonal segments.
By default the preferred polyline segment length is 30.
public function get preferredPolylineSegmentLength():Number
public function set preferredPolylineSegmentLength(value:Number):void
See also
registeredPartitionExtensions | property |
registeredPartitionExtensions:List
[read-only] Returns a list containing all registered com.yworks.yfiles.layout.router.polyline.GraphPartitionExtension s.
GraphPartitionExtensions
can be added and removed to change the composition of extensions used by the com.yworks.yfiles.layout.router.polyline.GraphPartition.
public function get registeredPartitionExtensions():List
See also
registeredPathSearchExtensions | property |
registeredPathSearchExtensions:List
[read-only] Returns a list containing all registered com.yworks.yfiles.layout.router.polyline.PathSearchExtension s.
com.yworks.yfiles.layout.router.polyline.PathSearchExtension can be added and removed to change the composition of extensions used by the com.yworks.yfiles.layout.router.polyline.PathSearch.
public function get registeredPathSearchExtensions():List
See also
rerouting | property |
rerouting:Boolean
Determines whether or not the edge router uses an additional step to reroute those edges that are considered to have the worst paths.
Rerouting is only used, if the maximumDuration isn't exceeded, yet.
By default rerouting is disabled.
public function get rerouting():Boolean
public function set rerouting(value:Boolean):void
See also
selectedEdgesDpKey | property |
selectedEdgesDpKey:Object
Specifies the data provider key used to look up the selected state of the edges of the graph to be laid out. By default, com.yworks.yfiles.layout.LayouterKeys.SELECTED_EDGES is used.
If the sphere of action is set to ROUTE_SELECTED_EDGES, only the selected keys are routed while all other edges are considered to have fixed routes.
public function get selectedEdgesDpKey():Object
public function set selectedEdgesDpKey(value:Object):void
IllegalArgumentException — if the specified key is null .
|
See also
selectedNodesDpKey | property |
selectedNodesDpKey:Object
Specifies the data provider key used to look up the selected state of the nodes of the graph to be laid out. By default, com.yworks.yfiles.layout.LayouterKeys.SELECTED_NODES is used.
If the sphere of action is set to ROUTE_EDGES_AT_SELECTED_NODES, only edges of selected nodes are routed while all other edges are considered to have fixed routes.
public function get selectedNodesDpKey():Object
public function set selectedNodesDpKey(value:Object):void
IllegalArgumentException — if the specified key is null .
|
See also
sphereOfAction | property |
sphereOfAction:int
Getter: Returns the currently set sphere of action specifier.
Setter: Sets the edge (sub-)set to be routed. Default setting is ROUTE_ALL_EDGES. public function get sphereOfAction():int
public function set sphereOfAction(value:int):void
IllegalArgumentException — if the given argument is not one of the above constants.
|
See also
EdgeRouter | () | Constructor |
public function EdgeRouter(init:Boolean = true)
Creates a new EdgeRouter instance.
Parametersinit:Boolean (default = true ) — An internally used switch to help handle proper instance initialization in inheritance chains where classes can have multiple constructor-like factory methods.
This parameter can safely be ignored/omitted when calling the constructor.
|
canLayout | () | method |
override public function canLayout(graph:LayoutGraph):Boolean
Parameters
graph:LayoutGraph |
Boolean |
checkGroupNodeSize | () | method |
protected function checkGroupNodeSize(layout:GraphLayout, node:Object):void
This method throws an com.yworks.bridge.util.IllegalArgumentException if the width/height of the given group node object is zero. It is called by the doLayout() method for each group node object in the input graph.
Parameters
layout:GraphLayout — a graph layout object.
| |
node:Object — the group node object to test.
|
IllegalArgumentException — thrown if the width/height of the group node object is zero.
|
See also
checkNodeSize | () | method |
protected function checkNodeSize(layout:GraphLayout, node:Object):void
This method throws an com.yworks.bridge.util.IllegalArgumentException if the width/height of the given node object is zero. It is called by the doLayout() method for each node object in the input graph.
Parameters
layout:GraphLayout — a graph layout object.
| |
node:Object — the node object to test.
|
IllegalArgumentException — thrown if the width/height of the node object is zero.
|
See also
cleanupGraphPartition | () | method |
protected function cleanupGraphPartition(partition:GraphPartition):void
Cleans up the given com.yworks.yfiles.layout.router.polyline.GraphPartition.
This implementation gets all registered com.yworks.yfiles.layout.router.polyline.GraphPartitionExtension s and removes them from the given GraphPartition
. It may be overridden to adjust the configuration of the GraphPartition
.
Parameters
partition:GraphPartition — the partition that shall be configured
|
See also
configureGraphPartition | () | method |
protected function configureGraphPartition(partition:GraphPartition):void
Configures the given com.yworks.yfiles.layout.router.polyline.GraphPartition.
This implementation gets all registered com.yworks.yfiles.layout.router.polyline.GraphPartitionExtension s and adds them to the given GraphPartition
. It may be overridden to adjust the configuration of the GraphPartition
.
Parameters
partition:GraphPartition — the partition that shall be configured
|
See also
configurePathSearch | () | method |
protected function configurePathSearch(pathSearch:PathSearch):void
Configures the given com.yworks.yfiles.layout.router.polyline.PathSearch.
This implementation gets all registered com.yworks.yfiles.layout.router.polyline.PathSearchExtension s and adds them to the given PathSearch
. It may be overridden to adjust the configuration of the PathSearch
.
Parameters
pathSearch:PathSearch — the path search that shall be configured
|
See also
createConfiguration | () | method |
protected function createConfiguration(graph:LayoutGraph, grouping:GraphGrouping):PathSearchConfiguration
Creates the com.yworks.yfiles.layout.router.polyline.PathSearchConfiguration that is used during the path search.
This implementation creates a new PathSearchConfiguration
. May be overridden to use a subclassed configuration.
Parameters
graph:LayoutGraph | |
grouping:GraphGrouping |
PathSearchConfiguration — A new PathSearchConfiguration .
|
See also
createDefaultEdgeOrderComparator | () | method |
protected function createDefaultEdgeOrderComparator(graph:LayoutGraph, configuration:PathSearchConfiguration):Comparator
Creates and returns the default java.util.Comparator used to determine the order the edges of the graph are laid out with.
Parameters
graph:LayoutGraph — The graph that contains the edges to compare.
| |
configuration:PathSearchConfiguration — The configuration to use for the following path searches.
|
Comparator — A comparator ordering edge s to determine the order the edges of the graph are laid out with.
|
See also
createGraphPartition | () | method |
protected function createGraphPartition(decomposition:ObstaclePartition):GraphPartition
Creates a com.yworks.yfiles.layout.router.polyline.GraphPartition that divides the area of the graph into several rectangles.
This implementation creates a GraphPartition
using the current com.yworks.yfiles.layout.router.polyline.ObstaclePartition . It may be overridden to customize the partition used in EdgeRouter
.
Parameters
decomposition:ObstaclePartition |
GraphPartition — a new GraphPartition
|
See also
createObstacleDecomposition | () | method |
protected function createObstacleDecomposition():DynamicObstacleDecomposition
Creates a com.yworks.yfiles.layout.router.polyline.DynamicObstacleDecomposition that is used by the com.yworks.yfiles.layout.router.polyline.GraphPartition to divide the graph area in rectangles.
This implementation creates a new DynamicObstacleDecomposition
. May be overridden to customize the area decomposition.
DynamicObstacleDecomposition — A new DynamicObstacleDecomposition
|
See also
createPathRouting | () | method |
protected function createPathRouting():ChannelBasedPathRouting
Creates a com.yworks.yfiles.layout.router.polyline.ChannelBasedPathRouting that routes the edges using pre-calculated com.yworks.yfiles.layout.router.polyline.Path objects.
This implementation creates a new ChannelBasedPathRouting
. May be overridden to customize the path routing.
ChannelBasedPathRouting — A new ChannelBasedPathRouting
|
See also
createPathSearch | () | method |
protected function createPathSearch():PathSearch
Creates a com.yworks.yfiles.layout.router.polyline.PathSearch that finds the edges' paths through the com.yworks.yfiles.layout.router.polyline.GraphPartition.
This implementation creates a new PathSearch
. May be overridden to customize the path search.
PathSearch — a new PathSearch
|
See also
createPathSearchContext | () | method |
protected function createPathSearchContext(pathSearch:PathSearch, configuration:PathSearchConfiguration):PathSearchContext
Creates a com.yworks.yfiles.layout.router.polyline.PathSearchContext that provides context information for the path search algorithm.
This implementation creates a new PathSearchContext
. May be overridden to customize the context information providing.
Parameters
pathSearch:PathSearch — The path search that uses the context to be created.
| |
configuration:PathSearchConfiguration — The configuration used for the path search.
|
PathSearchContext — A new PathSearchContext
|
See also
doLayout | () | method |
getClass | () | method |
override public function getClass():Class
ReturnsClass |
getEdgeLayoutDescriptor | () | method |
protected function getEdgeLayoutDescriptor(edge:Edge):EdgeLayoutDescriptor
Returns the com.yworks.yfiles.layout.router.polyline.EdgeLayoutDescriptor provided by the com.yworks.yfiles.base.DataProvider with the key EDGE_LAYOUT_DESCRIPTOR_DPKEY for the given edge.
For all those edges, that do not have a specific layout descriptor assigned, the default descriptor is returned.
Parameters
edge:Edge — The edge to return the layout descriptor for.
|
EdgeLayoutDescriptor — The layout descriptor used for the given edge.
|
See also
initEdgeRouter1 | () | method |
protected final function initEdgeRouter1():void
Initializes this object. See the documentation of the corresponding factory method newEdgeRouter1()
for details.
See also
initEdgeRouter2 | () | method |
protected final function initEdgeRouter2(core:Layouter):void
Initializes this object. See the documentation of the corresponding factory method newEdgeRouter2()
for details.
Parameters
core:Layouter |
See also
isSelected | () | method |
protected function isSelected(e:Edge, graph:Graph):Boolean
Utility method that returns the selection state of the given edge.
If the sphere of action is ROUTE_ALL_EDGES, true
is returned for all edges.
Parameters
e:Edge | |
graph:Graph |
Boolean |
See also
newEdgeRouter1 | () | method |
public static function newEdgeRouter1():EdgeRouter
Creates a new EdgeRouter instance.
ReturnsEdgeRouter |
newEdgeRouter2 | () | method |
public static function newEdgeRouter2(core:Layouter):EdgeRouter
Creates a new EdgeRouter instance with the given core Layouter.
Parameters
core:Layouter |
EdgeRouter |
EDGE_LAYOUT_DESCRIPTOR_DPKEY | Constant |
public static const EDGE_LAYOUT_DESCRIPTOR_DPKEY:String = y.layout.router.polyline.EdgeRouter.EDGE_LAYOUT_DESCRIPTOR_DPKEY
com.yworks.yfiles.base.DataProvider key used to store the com.yworks.yfiles.layout.router.polyline.EdgeLayoutDescriptor for each edge. If there is no descriptor mapped for an edge, the default descriptor is used.
See also
LABEL_CROSSING_COST_FACTOR_DPKEY | Constant |
public static const LABEL_CROSSING_COST_FACTOR_DPKEY:String = y.layout.router.polyline.EdgeRouter.LABEL_CROSSING_COST_FACTOR_DPKEY
com.yworks.yfiles.base.DataProvider key used to store a cost factor for each label.
This factor is multiplied with the basic penalty for an edge crossing a node label (com.yworks.yfiles.layout.router.polyline.PenaltySettings.nodeLabelCrossingPenalty) or edge label (com.yworks.yfiles.layout.router.polyline.PenaltySettings.edgeLabelCrossingPenalty) to determine the final costs to cross this label.
See also
ROUTE_ALL_EDGES | Constant |
public static const ROUTE_ALL_EDGES:int = 0
Sphere of action specifier. Route all edges of the input graph.
See also
ROUTE_EDGES_AT_SELECTED_NODES | Constant |
public static const ROUTE_EDGES_AT_SELECTED_NODES:int = 4
Sphere of action specifier. Route only edges connected to selected nodes. The selection state of a node is determined by a boolean value returned by the data provider associated with the data provider key selectedNodesDpKey.
See also
ROUTE_SELECTED_EDGES | Constant |
public static const ROUTE_SELECTED_EDGES:int = 2
Sphere of action specifier. Route only selected edges of the input graph. The selection state of an edge is determined by a boolean value returned by the data provider associated with the data provider key selectedEdgesDpKey.
See also