Comparator<NodeDistance>
public class NodeDistanceComparator extends Object implements Comparator<NodeDistance>
Constructor | Description |
---|---|
NodeDistanceComparator() |
Instantiates a new node distance comparator sorting the distances
ascending.
|
NodeDistanceComparator(boolean reverse) |
Instantiates a new node distance comparator.
|
Modifier and Type | Method | Description |
---|---|---|
int |
compare(NodeDistance o1,
NodeDistance o2) |
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
public NodeDistanceComparator()
public NodeDistanceComparator(boolean reverse)
true
subtrees are sorted in descending order, otherwise
ascending.reverse
- the reversepublic int compare(NodeDistance o1, NodeDistance o2)
compare
in interface Comparator<NodeDistance>
Copyright © 2018 SEMS project @ University of Rostock. All rights reserved.