T
- the property (like land/water or nation)public class GeoPropertyIndex<T> extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
protected static class |
GeoPropertyIndex.GPLevel<T> |
Modifier and Type | Field and Description |
---|---|
private static boolean |
DEBUG |
private GeoProperty<T> |
geoProp |
private GeoPropertyIndex.GPLevel<T> |
lastLevelUsed |
private int |
maxLevel |
private GeoPropertyIndex.GPLevel<T> |
root |
Constructor and Description |
---|
GeoPropertyIndex(GeoProperty<T> geoProp,
int maxLevel)
Create new GeoPropertyIndex.
|
Modifier and Type | Method and Description |
---|---|
T |
get(LatLon ll)
Look up the property for a certain point.
|
static int |
index(LatLon ll,
int level) |
java.lang.String |
toString() |
private final int maxLevel
private final GeoProperty<T> geoProp
private final GeoPropertyIndex.GPLevel<T> root
private GeoPropertyIndex.GPLevel<T> lastLevelUsed
private static final boolean DEBUG
public GeoPropertyIndex(GeoProperty<T> geoProp, int maxLevel)
geoProp
- the input property that should be made faster by this indexmaxLevel
- max levelpublic T get(LatLon ll)
GeoProperty.get(LatLon)
, but
should be faster.ll
- the point coordinatespublic java.lang.String toString()
toString
in class java.lang.Object