Class RoutingBase
Base class for routing algorithms.
Inheritance
Inherited Members
Namespace: Telerik.Windows.Diagrams.Core
Assembly: Telerik.WinControls.RadDiagram.dll
Syntax
public abstract class RoutingBase : IRouter
Constructors
RoutingBase(IGraphInternal)
Initializes a new instance of the RoutingBase class.
Declaration
protected RoutingBase(IGraphInternal graph)
Parameters
|
IGraphInternal
graph
The graph. |
Methods
ClockwiseMoveAroundEdgeOfShape(Point, IDiagramItem)
Given a point on the edge of a shape, this returns the middle point of the edge adjacent to it in the clockwise direction.
Declaration
protected static Point ClockwiseMoveAroundEdgeOfShape(Point point, IDiagramItem shape)
Parameters
|
Point
point
The point on the edge of the shape. |
|
IDiagramItem
shape
The shape holding the point. |
Returns
|
Point
|
Remarks
This method is called when the routing algorithm is unable to find a route from the given starting point and an alternative starting point at the edge of the shape is necessary.
FindCrossings(IConnection, ref Point, ref Point)
Finds the crossings.
Declaration
protected static void FindCrossings(IConnection connection, ref Point source, ref Point target)
Parameters
|
IConnection
connection
The connection. |
|
Point
source
The source. |
|
Point
target
The target. |
FindMostProbableTuple(IConnection)
Given the connection, the most probable start and end points are returned together with some additional points if necessary.
Declaration
protected static Tuple<Point, Point, Point, Point, Point, Point> FindMostProbableTuple(IConnection connection)
Parameters
|
IConnection
connection
The connection which is being routed. |
Returns
|
System.Tuple<Point, Point, Point, Point, Point, Point>
A tuple containing
|
GetRoutePoints(IConnection, Boolean)
Gets the route points.
Declaration
public abstract IList<Point> GetRoutePoints(IConnection connection, bool showLastLine = true)
Parameters
|
IConnection
connection
The connection. |
|
System.Boolean
showLastLine
If set to |
Returns
|
System.Collections.Generic.IList<Point>
|
Implements
GetSector(Point, Rect)
Gets the sector.
Declaration
protected static Sector GetSector(Point point, Rect bounds)
Parameters
|
Point
point
|
|
Rect
bounds
|
Returns
|
Sector
|
PointIsInNeighborhoodOfShape(Point)
Returns whether the given point is in the neighborhood of a shape.
Declaration
protected bool PointIsInNeighborhoodOfShape(Point point)
Parameters
|
Point
point
The point. |
Returns
|
System.Boolean
|
PointIsInShape(Point)
Returns whether the given point resides in one of the shapes in the diagram.
Declaration
protected bool PointIsInShape(Point point)
Parameters
|
Point
point
The point. |
Returns
|
System.Boolean
|