- java.lang.Object
-
- org.jgrapht.alg.tour.NearestInsertionHeuristicTSP.Closest<V>
-
- Type Parameters:
V
- vertex type
- All Implemented Interfaces:
java.lang.Comparable<NearestInsertionHeuristicTSP.Closest<V>>
- Enclosing class:
- NearestInsertionHeuristicTSP<V,E>
private static class NearestInsertionHeuristicTSP.Closest<V> extends java.lang.Object implements java.lang.Comparable<NearestInsertionHeuristicTSP.Closest<V>>
Class holding data for the closest unvisited vertex to a particular vertex in the tour.
-
-
Field Summary
Fields Modifier and Type Field Description private double
distance
private V
tourVertex
private V
unvisitedVertex
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(NearestInsertionHeuristicTSP.Closest<V> o)
double
getDistance()
V
getTourVertex()
V
getUnvisitedVertex()
-
-
-
Method Detail
-
getTourVertex
public V getTourVertex()
-
getUnvisitedVertex
public V getUnvisitedVertex()
-
getDistance
public double getDistance()
-
compareTo
public int compareTo(NearestInsertionHeuristicTSP.Closest<V> o)
- Specified by:
compareTo
in interfacejava.lang.Comparable<V>
-
-