static class NearestNeighbor.Cell extends java.lang.Object implements java.lang.Comparable<NearestNeighbor.Cell>
Modifier and Type | Field and Description |
---|---|
(package private) double |
distanceSortKey
The closest distance from a point in this cell to the query point, computed as a sort key through
SloppyMath.haversinSortKey(double, double, double, double) . |
(package private) BKDReader.IndexTree |
index |
(package private) byte[] |
maxPacked |
(package private) byte[] |
minPacked |
(package private) int |
readerIndex |
Constructor and Description |
---|
Cell(BKDReader.IndexTree index,
int readerIndex,
byte[] minPacked,
byte[] maxPacked,
double distanceSortKey) |
Modifier and Type | Method and Description |
---|---|
int |
compareTo(NearestNeighbor.Cell other) |
java.lang.String |
toString() |
final int readerIndex
final byte[] minPacked
final byte[] maxPacked
final BKDReader.IndexTree index
final double distanceSortKey
SloppyMath.haversinSortKey(double, double, double, double)
. Note that this is an approximation to the closest distance,
and there could be a point in the cell that is closer.public Cell(BKDReader.IndexTree index, int readerIndex, byte[] minPacked, byte[] maxPacked, double distanceSortKey)
public int compareTo(NearestNeighbor.Cell other)
compareTo
in interface java.lang.Comparable<NearestNeighbor.Cell>
public java.lang.String toString()
toString
in class java.lang.Object