T - The type of object stored on the edges in the graph.public class EdgeFromAngleComparator<T> extends Object implements Comparator<Edge<T>>
| Constructor and Description |
|---|
EdgeFromAngleComparator()
Construct a new EdgeComparitor.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compare(Edge<T> edge1,
Edge<T> edge2)
Compare the two edges at a given node.
|
static <T> EdgeFromAngleComparator<T> |
get() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequalspublic EdgeFromAngleComparator()
public static <T> EdgeFromAngleComparator<T> get()
public int compare(Edge<T> edge1, Edge<T> edge2)
Compare the two edges at a given node. The comparison is calculated in the following order.
Edge#getExitAngle(Node) from the node
for the two edges are compared.
compare in interface Comparator<Edge<T>>edge1 - The first edge.edge2 - The second edge.Angle.getTurn(double, double)Copyright © 2015 Revolution Systems Inc.. All rights reserved.