public class Geobox extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
BITS_0_40075004m
0 bits gives a box of 40075004m at the Equator
|
static int |
BITS_1_20037502m
1 bits gives a box of 20037502m at the Equator
|
static int |
BITS_10_39135m
10 bits gives a box of 39135m at the Equator
|
static int |
BITS_10_39km
Deprecated.
|
static int |
BITS_11_19567m
11 bits gives a box of 19567m at the Equator
|
static int |
BITS_12_10km
Deprecated.
|
static int |
BITS_12_9783m
12 bits gives a box of 9783m at the Equator
|
static int |
BITS_13_4891m
13 bits gives a box of 4891m at the Equator
|
static int |
BITS_14_2445m
14 bits gives a box of 2445m at the Equator
|
static int |
BITS_15_1222m
15 bits gives a box of 1222m at the Equator
|
static int |
BITS_15_1224m
Deprecated.
|
static int |
BITS_16_611m
16 bits gives a box of 611m at the Equator
|
static int |
BITS_17_305m
17 bits gives a box of 305m at the Equator
|
static int |
BITS_17_307m
Deprecated.
|
static int |
BITS_18_152m
18 bits gives a box of 152m at the Equator
|
static int |
BITS_18_154m
Deprecated.
|
static int |
BITS_19_76m
19 bits gives a box of 76m at the Equator
|
static int |
BITS_19_77m
Deprecated.
|
static int |
BITS_2_10018751m
2 bits gives a box of 10018751m at the Equator
|
static int |
BITS_20_38m
20 bits gives a box of 38m at the Equator
|
static int |
BITS_20_39m
Deprecated.
|
static int |
BITS_21_19m
21 bits gives a box of 19m at the Equator
|
static int |
BITS_22_10m
Deprecated.
|
static int |
BITS_22_9m
22 bits gives a box of 9m at the Equator
|
static int |
BITS_23_4m
23 bits gives a box of 4m at the Equator
|
static int |
BITS_23_53dm
Deprecated.
|
static int |
BITS_24_2m
24 bits gives a box of 2m at the Equator
|
static int |
BITS_24_32dm
Deprecated.
|
static int |
BITS_25_1m
25 bits gives a box of 1m at the Equator
|
static int |
BITS_26_0m
26 bits gives a box of 0m at the Equator
|
static int |
BITS_3_5009375m
3 bits gives a box of 5009375m at the Equator
|
static int |
BITS_4_2504687m
4 bits gives a box of 2504687m at the Equator
|
static int |
BITS_5_1252343m
5 bits gives a box of 1252343m at the Equator
|
static int |
BITS_6_626171m
6 bits gives a box of 626171m at the Equator
|
static int |
BITS_7_313085m
7 bits gives a box of 313085m at the Equator
|
static int |
BITS_8_156542m
8 bits gives a box of 156542m at the Equator
|
static int |
BITS_9_78271m
9 bits gives a box of 78271m at the Equator
|
static int |
D |
static int |
RADIUS |
| Constructor and Description |
|---|
Geobox() |
| Modifier and Type | Method and Description |
|---|---|
static double |
distance(DLocation p1,
DLocation p2)
Calculates the great circle distance between two points (law of cosines).
|
static double |
distance(double p1lat,
double p1lon,
double p2lat,
double p2lon)
Calculates the great circle distance between two points (law of cosines).
|
static int |
getCellSize(int bits) |
static double |
getCellSize(int bits,
double latitude) |
static long |
getHash(float lat,
float lng,
int bits) |
protected static long |
getHashIterative(float major,
float minor,
int bits) |
static long |
getMask(float x,
float base,
int bits) |
static Set<Long> |
getTuple(float lat,
float lng,
int bits) |
static double |
makeDoubleInRange(double d)
This function is used to fix issue 10:
GeocellUtils.distance(...) uses Math.acos(arg) method.
|
public static final int RADIUS
public static final int D
@Deprecated public static final int BITS_10_39km
@Deprecated public static final int BITS_12_10km
@Deprecated public static final int BITS_15_1224m
@Deprecated public static final int BITS_17_307m
@Deprecated public static final int BITS_18_154m
@Deprecated public static final int BITS_19_77m
@Deprecated public static final int BITS_20_39m
@Deprecated public static final int BITS_22_10m
@Deprecated public static final int BITS_23_53dm
@Deprecated public static final int BITS_24_32dm
public static final int BITS_0_40075004m
public static final int BITS_1_20037502m
public static final int BITS_2_10018751m
public static final int BITS_3_5009375m
public static final int BITS_4_2504687m
public static final int BITS_5_1252343m
public static final int BITS_6_626171m
public static final int BITS_7_313085m
public static final int BITS_8_156542m
public static final int BITS_9_78271m
public static final int BITS_10_39135m
public static final int BITS_11_19567m
public static final int BITS_12_9783m
public static final int BITS_13_4891m
public static final int BITS_14_2445m
public static final int BITS_15_1222m
public static final int BITS_16_611m
public static final int BITS_17_305m
public static final int BITS_18_152m
public static final int BITS_19_76m
public static final int BITS_20_38m
public static final int BITS_21_19m
public static final int BITS_22_9m
public static final int BITS_23_4m
public static final int BITS_24_2m
public static final int BITS_25_1m
public static final int BITS_26_0m
public static long getMask(float x,
float base,
int bits)
public static long getHash(float lat,
float lng,
int bits)
protected static long getHashIterative(float major,
float minor,
int bits)
public static double distance(DLocation p1, DLocation p2)
p1 - indicating the first point.p2 - indicating the second point.public static double makeDoubleInRange(double d)
d - public static int getCellSize(int bits)
public static double getCellSize(int bits,
double latitude)
public static double distance(double p1lat,
double p1lon,
double p2lat,
double p2lon)
p1lat - indicating the first point latitude.p1lon - indicating the first point longitude.p2lat - indicating the second point latitudep2lon - indicating the second point longitudeCopyright © 2014 Wadpam. All Rights Reserved.