Module org.jgrapht.core
Package org.jgrapht.alg.shortestpath
Class BaseBidirectionalShortestPathAlgorithm.BaseSearchFrontier<V,E>
java.lang.Object
org.jgrapht.alg.shortestpath.BaseBidirectionalShortestPathAlgorithm.BaseSearchFrontier<V,E>
- Type Parameters:
V
- vertices typeE
- edges type
- Direct Known Subclasses:
BidirectionalAStarShortestPath.AStarSearchFrontier
,BidirectionalDijkstraShortestPath.DijkstraSearchFrontier
- Enclosing class:
BaseBidirectionalShortestPathAlgorithm<V,
E>
Base class of the search frontier used by bidirectional shortest path algorithms.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) abstract double
getDistance
(V v) Returns distance to vertexv
computed so far.(package private) abstract E
getTreeEdge
(V v) Returns edge which connectsv
to its predecessor in the shortest paths tree of this frontier.
-
Field Details
-
graph
Frontier`s graph.
-
-
Constructor Details
-
BaseSearchFrontier
Constructs instance for a givengraph
.- Parameters:
graph
- graph
-
-
Method Details
-
getDistance
Returns distance to vertexv
computed so far.- Parameters:
v
- vertex- Returns:
- distance to
v
-
getTreeEdge
Returns edge which connectsv
to its predecessor in the shortest paths tree of this frontier.- Parameters:
v
- vertex- Returns:
- edge in shortest paths tree
-