Routify Documentation
Loading...
Searching...
No Matches
ch.routify.routing.Routing Class Reference

Static Public Member Functions

static GraphPath< CustomVertex, CustomEdgeaStar (CustomVertex cFrom, CustomVertex cTo, HashMap< CustomEdge, Double > weights, CustomAsSubgraph< CustomVertex, CustomEdge > graph) throws Exception
 

Detailed Description

Provides routing functionalities using graph-based algorithms and custom criteria. This class includes methods for calculating routes based on various environmental factors like slope, green index, noise, air quality, and traffic. It integrates with the JGraphT library to perform graph operations and utilizes custom classes for vertices, edges, and subgraphs.

Member Function Documentation

◆ aStar()

static GraphPath< CustomVertex, CustomEdge > ch.routify.routing.Routing.aStar ( CustomVertex cFrom,
CustomVertex cTo,
HashMap< CustomEdge, Double > weights,
CustomAsSubgraph< CustomVertex, CustomEdge > graph ) throws Exception
inlinestatic

Calculates the shortest path between two points using the A* algorithm and an admissible heuristic.

Parameters
cFromThe starting point as a CustomVertex.
cToThe ending point as a CustomVertex.
weightsA HashMap containing the weights of the edges.
graphThe graph represented as a CustomAsSubgraph.
Returns
A GraphPath representing the shortest path between the two points.
Exceptions
Exceptionif the path cannot be calculated.

The documentation for this class was generated from the following file: