public class GeoLocationService extends Object
| Modifier and Type | Field and Description |
|---|---|
static double |
DIAMETER_OF_EARTH |
| Constructor and Description |
|---|
GeoLocationService() |
| Modifier and Type | Method and Description |
|---|---|
static double |
degreesToRadians(double degrees)
Converts the given value from degrees to radians.
|
static double |
getDistanceBetweenPoints(de.alpharogroup.jgeohash.Point p1,
de.alpharogroup.jgeohash.Point p2,
String unit)
Returns the distance between tow points.
|
static double |
getExtremeLatitudesDiffForPoint(de.alpharogroup.jgeohash.Point p1,
double distance)
Returns the difference in degrees of latitude corresponding to the distance from the center
point.
|
static double |
getExtremeLongitudesDiffForPoint(de.alpharogroup.jgeohash.Point p1,
double distance)
Returns the difference in degrees of longitude corresponding to the distance from the center
point.
|
static de.alpharogroup.jgeohash.Point[] |
getExtremePointsFrom(de.alpharogroup.jgeohash.Point point,
Double distance)
Returns an array of two extreme points corresponding to center point and the distance from
the center point.
|
static void |
main(String[] args)
The main method.
|
static double |
radiansToDegrees(double radians)
Converts the given value radians to degrees.
|
public static final double DIAMETER_OF_EARTH
public static double degreesToRadians(double degrees)
degrees - the degreespublic static double getDistanceBetweenPoints(de.alpharogroup.jgeohash.Point p1,
de.alpharogroup.jgeohash.Point p2,
String unit)
p1 - the p1p2 - the p2unit - the unitpublic static double getExtremeLatitudesDiffForPoint(de.alpharogroup.jgeohash.Point p1,
double distance)
p1 - the p1distance - the distancepublic static double getExtremeLongitudesDiffForPoint(de.alpharogroup.jgeohash.Point p1,
double distance)
p1 - the p1distance - the distancepublic static de.alpharogroup.jgeohash.Point[] getExtremePointsFrom(de.alpharogroup.jgeohash.Point point,
Double distance)
point - the pointdistance - the distancepublic static void main(String[] args)
args - the argumentspublic static double radiansToDegrees(double radians)
radians - the radiansCopyright © 2015–2017 Alpha Ro Group UG (haftungsbeschrÀngt). All rights reserved.