Class. Junction Finder
protected
findJunctionPointsWithSameSource(edge
,route
,routing
):void
Defined in: packages/sprotty/src/features/edge-junction/junction-finder.ts:81
Finds the junction points of routes with the same source
void
protected
findJunctionPointsWithSameTarget(edge
,route
,routing
):void
Defined in: packages/sprotty/src/features/edge-junction/junction-finder.ts:109
Finds the junction points of routes with the same target
void
protected
findJunctions(routing
,parent
):void
Defined in: packages/sprotty/src/features/edge-junction/junction-finder.ts:41
void
protected
getJunctionIndex(firstRoute
,secondRoute
):number
Defined in: packages/sprotty/src/features/edge-junction/junction-finder.ts:230
Finds the index where two routes diverge. Returns -1 if no divergence can be found.
number
protected
getSegmentDirection(firstPoint
,secondPoint
):"left"
|"right"
|"down"
|"up"
Defined in: packages/sprotty/src/features/edge-junction/junction-finder.ts:202
Get the main direction of a segment. The main direction is the axis with the greatest difference between the two points.
"left"
| "right"
| "down"
| "up"
protected
setJunctionPoints(route
,otherRoute
,junctionIndex
):void
Defined in: packages/sprotty/src/features/edge-junction/junction-finder.ts:146
Set the junction points of two routes according to the segments direction. If the segments have different directions, the junction point is the previous common point. If the segments have the same direction, the junction point is the point with the greatest or lowest value axis value depending on the direction.
number
void
protected
setPreviousPointAsJunction(route
,sameSourceRoute
,junctionIndex
):void
Defined in: packages/sprotty/src/features/edge-junction/junction-finder.ts:193
Set the previous point as a junction point. This is used when two segments have the same direction but the other axis is different. For example if the routes are going in opposite directions, or if the route don’t split orthogonally.
number
void