This class is used by HierarchicalLayout during the various phases to provide routing details for the edges of the graph.
Remarks
A HierarchicalLayoutEdgeDescriptor instance can be specified individually for single edges via property edgeDescriptors.
This class is designed as a class to allow future additions of new getter methods.
Default Values of Properties
minimumDistance | 10.0d | |
minimumFirstSegmentLength | 10.0d | |
minimumLastSegmentLength | 15.0d | |
minimumLength | 20.0d | |
minimumOctilinearSegmentLength | 20.0d | |
minimumSlope | 0.2 | |
recursiveEdgePolicy | OFF
| Edges are not routed recursively. |
Type Details
- yFiles module
- algorithms
See Also
Constructors
Creates a new instance of a HierarchicalLayoutEdgeDescriptor with the default values.
Parameters
A map of options to pass to the method.
- minimumFirstSegmentLength - number
- The minimum length of the first segment of the edge path (at the source node). This option sets the minimumFirstSegmentLength property on the created object.
- minimumLastSegmentLength - number
- The minimum length of the last segment of the edge path (at the target node). This option sets the minimumLastSegmentLength property on the created object.
- minimumLength - number
- The minimum length of an edge. This option sets the minimumLength property on the created object.
- minimumDistance - number
- The preferred minimum distance to obstacles. This option sets the minimumDistance property on the created object.
- minimumSlope - number
- The minimum slope that the mid segments of this edge should have, if the edge is routed polyline in vertical layouts. This option sets the minimumSlope property on the created object.
- routingStyleDescriptor - RoutingStyleDescriptor
- The routing style descriptor for this edge. This option either sets the value directly or recursively sets properties to the instance of the routingStyleDescriptor property on the created object.
- minimumOctilinearSegmentLength - number
- The minimum length of octilinear segments for this edge. This option sets the minimumOctilinearSegmentLength property on the created object.
- recursiveEdgePolicy - RecursiveEdgePolicy
- How edges in grouped graphs are routed between the content of different groups. This option sets the recursiveEdgePolicy property on the created object.
- directGroupContentEdgeRouting - boolean
- Whether or not this edge is routed directly to a group node's border if it connects the group node with one of its descendants. This option sets the directGroupContentEdgeRouting property on the created object.
- backLoopRouting - boolean
- Whether or not reversed edges or self-loops should be routed as back-loops. This option sets the backLoopRouting property on the created object.
Properties
Gets or sets whether or not reversed edges or self-loops should be routed as back-loops.
Remarks
When this option is enabled, back-loops attach to the same node sides as the other edges, i.e., for layout orientation top-to-bottom, they leave their source at the bottom and enter their target at the top.
This property only affects reversed edges and self-loops. It has no effect on other edges.
Default Value
false
.There is no back-loop routing applied to reversed edges.
Property Value
true
if back-loop routing is applied, false
otherwiseSample Graphs
0
) are never routed as back-loops because they have no dedicated source/target node. Furthermore, for edges with a negative directedness value the source and target are interchanged.Gets or sets whether or not this edge is routed directly to a group node's border if it connects the group node with one of its descendants.
Remarks
Default Value
false
.Property Value
true
if the edge is routed directly, false
otherwiseSample Graphs
Gets or sets the preferred minimum distance to obstacles.
Remarks
0
.Default Value
10.0d
.Property Value
Throws
- Exception({ name: 'ArgumentError' })
- if the minimum length is negative
Sample Graphs
Gets or sets the minimum length of the first segment of the edge path (at the source node).
Remarks
The minimum length should be greater than 0
.
If the value is 0.0d
, the first segment does not need to be orthogonal.
Default Value
10.0d
.Property Value
Throws
- Exception({ name: 'ArgumentError' })
- if the minimum length of the first segment is negative
Sample Graphs
Gets or sets the minimum length of the last segment of the edge path (at the target node).
Remarks
The minimum length should be greater than 0
.
If the value is 0.0d
, the last segment does not need to be orthogonal.
Default Value
15.0d
.Property Value
Throws
- Exception({ name: 'ArgumentError' })
- if the minimum length of the last segment is negative
Sample Graphs
Gets or sets the minimum length of an edge.
Remarks
If this is used for polyline routing, it describes the minimum vertical length of the mid segment. If it is used for orthogonal routing, it describes the minimum length of the whole edge (i.e., the sum of the length of all segments).
The minimum length should be greater than 0
.
Default Value
20.0d
.Property Value
Throws
- Exception({ name: 'ArgumentError' })
- if the minimum length is negative
Sample Graphs
Gets or sets the minimum length of octilinear segments for this edge.
Default Value
20.0d
.Property Value
Throws
- Exception({ name: 'ArgumentError' })
- if the minimum length of the first segment is negative
See Also
Sample Graphs
Gets or sets the minimum slope that the mid segments of this edge should have, if the edge is routed polyline in vertical layouts.
Remarks
In addition, this value influences the steepness for CURVED edges.
The minimum slope should be greater than 0
. For the curved routing style, larger values lead to steeper curves. Steeper curves generally require more height but less width (vertical layout direction).
Default Value
0.2
.Property Value
Throws
- Exception({ name: 'ArgumentError' })
- if the given minimum slope is negative
Sample Graphs
Gets or sets how edges in grouped graphs are routed between the content of different groups.
Default Value
Property Value
Sample Graphs
Gets or sets the routing style descriptor for this edge.
Default Value
RoutingStyleDescriptor.An instance where all types of edges are routed orthogonal.
Property Value
Throws
- Exception({ name: 'ArgumentError' })
- if the given routing style is null
Sample Graphs
Methods
Creates a copy of this HierarchicalLayoutEdgeDescriptor instance.
Returns
- ↪HierarchicalLayoutEdgeDescriptor
- a copy of this HierarchicalLayoutEdgeDescriptor instance