Interface IRoutePlanner
The routing component able to find the best from a source node to a target node.
Assembly: Mars.Interfaces.dll
Syntax
public interface IRoutePlanner
Methods
|
Improve this Doc
View Source
FindFastestRoute(ISpatialNode, ISpatialNode, Func<ISpatialEdge, Boolean>)
Calculates a
Route from
source to
target in which the whole length is
the fastest (as travel time in seconds) under consideration of max speed. When no route was found
null will be returned.
Declaration
Route FindFastestRoute(ISpatialNode source, ISpatialNode target, Func<ISpatialEdge, bool> filter = null)
Parameters
Returns
| Type |
Description |
| Route |
Returns a common Route container, containing the path from from to target
which is the fastest (travel time) or null when no route was found.
|
|
Improve this Doc
View Source
FindRoute(ISpatialNode, ISpatialNode, Func<ISpatialNode, ISpatialEdge, ISpatialNode, Double>, Func<ISpatialEdge, Boolean>)
Calculates a route from a given from node to a specified to node and constructed
using the passed heuristic function applying a cost on each visited edge e.g. the length or travel-time.
Using the optional filter the whole network can first be filtered out for all edges evaluate to true.
Declaration
Route FindRoute(ISpatialNode from, ISpatialNode to, Func<ISpatialNode, ISpatialEdge, ISpatialNode, double> heuristic = null, Func<ISpatialEdge, bool> filter = null)
Parameters
| Type |
Name |
Description |
| ISpatialNode |
from |
INode where the search starts |
| ISpatialNode |
to |
INode where the search ends |
| System.Func<ISpatialNode, ISpatialEdge, ISpatialNode, System.Double> |
heuristic |
The heuristic function which receives an
input start node, the actual visited edge associated with
from an to and the goal node
|
| System.Func<ISpatialEdge, System.Boolean> |
filter |
The subgraph predicate to filter only those next edges which are evaluate to true. |
Returns
| Type |
Description |
| Route |
Returns a common Route container responsible
for all route updates and the underlying path of edges and nodes.
|
|
Improve this Doc
View Source
FindShortestHopRoute(ISpatialNode, ISpatialNode, Func<ISpatialEdge, Boolean>)
Calculates a
Route which has the minimum number of intermediate edge
between
source and
target.
Declaration
Route FindShortestHopRoute(ISpatialNode source, ISpatialNode target, Func<ISpatialEdge, bool> filter = null)
Parameters
Returns
| Type |
Description |
| Route |
Returns a new Route with minimum amount of intermediate
edge or null when no path was found.
|
|
Improve this Doc
View Source
FindShortestRoute(ISpatialNode, ISpatialNode, Func<ISpatialEdge, Boolean>)
Calculates a
Route from
source to
target in which the whole length is
the shortest to the desired destination or
null if no rout to the target was found.
Declaration
Route FindShortestRoute(ISpatialNode source, ISpatialNode target, Func<ISpatialEdge, bool> filter = null)
Parameters
Returns
| Type |
Description |
| Route |
Returns a common Route container, containing the path from from to target
which is the shortest (minimum length) or null when no route was found.
|
Extension Methods