public class Position
extends java.lang.Object
Constructor and Description |
---|
Position(double dblLat,
double dblLng)
A new position expressed in decimal format
|
Position(int latDeg,
float latMin,
int latQuad,
int lngDeg,
float lngMin,
int lngQuad)
A new position expressed in DegMin format
|
Position(java.lang.String lat,
java.lang.String lng)
A new position expressed in ALRS format
|
Position(java.lang.String latNMEAGPS,
java.lang.String latQuad,
java.lang.String lngNMEAGPS,
java.lang.String lngQuad,
java.lang.String utcTimeStamp)
A new position expressed in NMEA GPS message format:
4807.038,N,01131.000,E
|
Modifier and Type | Method and Description |
---|---|
void |
associateUTCTime(java.lang.String data)
Add a reference time for this position - useful for historical tracking
|
double |
getLatitude()
Return the position latitude in decimal format
|
double |
getLongitude()
Return the position longitude in decimal format
|
static void |
main(java.lang.String[] argsc) |
java.lang.String |
toStringDec()
Prints out position using decimal format
|
java.lang.String |
toStringDecLat()
Prints out the position latitude
|
java.lang.String |
toStringDecLng()
Prints out the position longitude
|
java.lang.String |
toStringDegMin()
Prints out position using DegMin format
|
java.lang.String |
toStringDegMinLat()
Prints out the position latitude
|
java.lang.String |
toStringDegMinLng()
Prints out the position longitude
|
java.lang.String |
utcTimeStamp()
Returns the UTC time stamp
|
public Position(double dblLat, double dblLng) throws InvalidPositionException
dblLat
- dblLng
- InvalidPositionException
public Position(int latDeg, float latMin, int latQuad, int lngDeg, float lngMin, int lngQuad) throws InvalidPositionException
latDeg
- latMin
- lngDeg
- lngMin
- InvalidPositionException
public Position(java.lang.String lat, java.lang.String lng) throws InvalidPositionException
lat
- lng
- InvalidPositionException
public Position(java.lang.String latNMEAGPS, java.lang.String latQuad, java.lang.String lngNMEAGPS, java.lang.String lngQuad, java.lang.String utcTimeStamp)
latNMEAGPS
- latQuad
- lngNMEAGPS
- lngQuad
- utcTimeStamp
- public void associateUTCTime(java.lang.String data)
data
- public java.lang.String utcTimeStamp()
public java.lang.String toStringDec()
public double getLatitude()
public double getLongitude()
public java.lang.String toStringDegMin()
public java.lang.String toStringDegMinLat()
public java.lang.String toStringDegMinLng()
public java.lang.String toStringDecLat()
public java.lang.String toStringDecLng()
public static void main(java.lang.String[] argsc)