|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.netxms.client.GeoLocation
public class GeoLocation
Geolocation encoding
Field Summary | |
---|---|
static int |
GPS
|
static int |
MANUAL
|
static int |
UNSET
|
Constructor Summary | |
---|---|
GeoLocation(boolean isGPS)
Create geolocation object of type UNSET or GPS |
|
GeoLocation(double lat,
double lon)
Create geolocation object of type MANUAL |
|
GeoLocation(NXCPMessage msg)
Create geolocation object from NXCP message |
Method Summary | |
---|---|
double |
getLatitude()
|
java.lang.String |
getLatitudeAsString()
|
double |
getLongitude()
|
java.lang.String |
getLongitudeAsString()
|
int |
getType()
|
static java.lang.String |
latitudeToString(double lat)
Convert latitude from floating point to text representation |
static java.lang.String |
longitudeToString(double lon)
Convert longitude from floating point to text representation |
static GeoLocation |
parseGeoLocation(java.lang.String lat,
java.lang.String lon)
Parse geolocation string. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int UNSET
public static final int MANUAL
public static final int GPS
Constructor Detail |
---|
public GeoLocation(NXCPMessage msg)
msg
- NXCP messagepublic GeoLocation(boolean isGPS)
public GeoLocation(double lat, double lon)
lat
- Latitudelon
- LongitudeMethod Detail |
---|
public int getType()
public double getLatitude()
public double getLongitude()
public java.lang.String toString()
toString
in class java.lang.Object
public static java.lang.String latitudeToString(double lat)
lat
- latitude
public static java.lang.String longitudeToString(double lon)
lon
- longitude
public java.lang.String getLatitudeAsString()
public java.lang.String getLongitudeAsString()
public static GeoLocation parseGeoLocation(java.lang.String lat, java.lang.String lon) throws GeoLocationFormatException
lat
- latitude stringlon
- longitude string
GeoLocationFormatException
- if the strings does not contain a parsable geolocation
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |