Constructor and Description |
---|
GraphPathImpl(Graph<V,E> graph,
V startVertex,
V endVertex,
List<E> edgeList,
double weight) |
Modifier and Type | Method and Description |
---|---|
List<E> |
getEdgeList()
Returns the edges making up the path.
|
V |
getEndVertex()
Returns the end vertex in the path.
|
Graph<V,E> |
getGraph()
Returns the graph over which this path is defined.
|
V |
getStartVertex()
Returns the start vertex in the path.
|
double |
getWeight()
Returns the weight assigned to the path.
|
String |
toString() |
public Graph<V,E> getGraph()
GraphPath
public V getStartVertex()
GraphPath
getStartVertex
in interface GraphPath<V,E>
public V getEndVertex()
GraphPath
getEndVertex
in interface GraphPath<V,E>
public List<E> getEdgeList()
GraphPath
Graphs.getPathVertexList(org.jgrapht.GraphPath<V, E>)
provides a convenience method for this.
Whether or not the returned edge list is modifiable depends on the path implementation.
getEdgeList
in interface GraphPath<V,E>
public double getWeight()
GraphPath
Copyright © 2016. All rights reserved.