Class GpsInformation
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
Indicates the altitude used as the reference altitude in the GPS information/data. -
Constructor Summary
ConstructorsConstructorDescriptionGpsInformation
(double latitude, double longitude) Creates a new instance of GPS information definition.GpsInformation
(double latitude, double longitude, float altitude, @NotNull String latitudeRef, @NotNull String longitudeRef, GpsInformation.AltitudeReference altitudeRef, float dop, @NotNull String mapDatum, @NotNull String satellites, @NotNull Date timeStamp) Creates a new instance of GPS information definition. -
Method Summary
Modifier and TypeMethodDescriptionboolean
double
The altitude.Altitude reference indicates if the altitude value is below or above see level.double
getDop()
Gps DOP (data degree of precision).double
The latitude.Latitude reference.double
The longitude.Longitude reference.Map datum.The satellites.The time.int
hashCode()
boolean
isValid()
A value indicating whether this GPS information is valid.void
setAltitude
(float altitude) The altitude.void
setAltitudeRef
(GpsInformation.AltitudeReference altitudeRef) Altitude reference indicates if the altitude value is below or above see level.void
setDop
(float dop) Gps DOP (data degree of precision).void
setLatitude
(double latitude) The latitude.void
setLatitudeRef
(@NotNull String latitudeRef) Latitude reference.void
setLongitude
(double longitude) The longitude.void
setLongitudeRef
(@NotNull String longitudeRef) Longitude reference.void
setMapDatum
(@NotNull String mapDatum) Map datum.void
setSatellites
(@NotNull String satellites) The satellites.void
setTimeStamp
(Date timeStamp) The time.toString()
-
Constructor Details
-
GpsInformation
public GpsInformation(double latitude, double longitude) Creates a new instance of GPS information definition.- Parameters:
latitude
- The latitude.longitude
- The longitude.
-
GpsInformation
public GpsInformation(double latitude, double longitude, float altitude, @NotNull @NotNull String latitudeRef, @NotNull @NotNull String longitudeRef, GpsInformation.AltitudeReference altitudeRef, float dop, @NotNull @NotNull String mapDatum, @NotNull @NotNull String satellites, @NotNull @NotNull Date timeStamp) throws IllegalArgumentException Creates a new instance of GPS information definition.- Parameters:
latitude
- The latitude.longitude
- The longitude.altitude
- The altitude.latitudeRef
- Latitude reference. Valid values are 'N' for the north latitude, and 'S' for the south latitude. May be left empty.longitudeRef
- Longitude reference. Valid values are 'E' for the east longitude, and 'W' for the west longitude. May be left empty.altitudeRef
- Altitude reference.dop
- Gps DOP (data degree of precision).mapDatum
- Map datum. Indicates the geodetic survey data used by the GPS receiver.satellites
- The satellites. This tag can be used to describe the number of satellites, their ID number, etc.timeStamp
- Indicates the time as UTC (Coordinated Universal Time).- Throws:
IllegalArgumentException
- when the input values are not valid
-
-
Method Details
-
isValid
public boolean isValid()A value indicating whether this GPS information is valid. Note: valid GPS data has at least non-zero latitude and longitude. -
getDop
public double getDop()Gps DOP (data degree of precision). -
setDop
public void setDop(float dop) Gps DOP (data degree of precision). -
getAltitude
public double getAltitude()The altitude. Note: If the altitude reference is below sea level, the altitude is indicated as an absolute value in altitude. The unit is meters. -
setAltitude
public void setAltitude(float altitude) The altitude. Note: If the altitude reference is below sea level, the altitude is indicated as an absolute value in altitude. The unit is meters. -
getAltitudeRef
Altitude reference indicates if the altitude value is below or above see level. -
setAltitudeRef
Altitude reference indicates if the altitude value is below or above see level. -
getLatitude
public double getLatitude()The latitude. -
setLatitude
public void setLatitude(double latitude) The latitude. -
getLatitudeRef
Latitude reference.Indicates whether the latitude is north or south latitude. The value 'N' indicates north latitude, and 'S' is south latitude.
-
setLatitudeRef
Latitude reference.Indicates whether the latitude is north or south latitude. Valid values are 'N' for the north latitude, and 'S' for the south latitude. Value can be also left empty if no information is available.
- Throws:
IllegalArgumentException
- when the input value is not valid
-
getLongitude
public double getLongitude()The longitude. -
setLongitude
public void setLongitude(double longitude) The longitude. -
getLongitudeRef
Longitude reference.Indicates whether the longitude is east or west longitude. The value 'E' indicates east longitude, and 'W' is west longitude.
-
setLongitudeRef
Longitude reference.Indicates whether the longitude is east or west longitude. Valid values are 'E' for the east longitude, and 'W' for the west longitude. Value can be also left empty if no information is available.
- Throws:
IllegalArgumentException
- when the input value is not valid
-
getMapDatum
Map datum.Indicates the geodetic survey data used by the GPS receiver.
-
setMapDatum
Map datum.Indicates the geodetic survey data used by the GPS receiver.
-
getSatellites
The satellites.Indicates the GPS satellites used for measurements. This tag can be used to describe the number of satellites, their ID number, angle of elevation, azimuth, SNR and other information in ASCII notation.
-
setSatellites
The satellites.Indicates the GPS satellites used for measurements. This tag can be used to describe the number of satellites, their ID number, angle of elevation, azimuth, SNR and other information in ASCII notation.
-
getTimeStamp
The time.Indicates the time as UTC (Coordinated Universal Time).
-
setTimeStamp
The time.Indicates the time as UTC (Coordinated Universal Time).
-
equals
-
hashCode
public int hashCode() -
toString
-