public class GPSData
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected boolean |
jniCMemOwn |
protected long |
jniCPtr |
com.ptvag.navigation.sdk.NativeObject |
parent |
Constructor and Description |
---|
GPSData()
Constructor
|
GPSData(long cPtr,
boolean cMemoryOwn)
Only for internal use - don't try to call this from Java.
|
Modifier and Type | Method and Description |
---|---|
void |
delete()
Kills rubbish if owning the object.
|
protected void |
finalize() |
int |
getAltitude()
Returns the altitude [m] as reported from GPS (may or may not include geoid
correction).
|
int |
getCourse()
Returns the navigation direction ([0..360[ 0=East, 90=North).
|
static long |
getCPtr(com.ptvag.navigation.sdk.NativeObject obj) |
java.util.Date |
getDate()
Returns a timestamp with the following information:
Date of fix [day of month * 10000 + month of year * 100 + (year>=2000)?
|
int |
getExtraPolatedCourse()
Returns the extrapolated Navigation direction ([0..360[ 0=East, 90=North)
|
Position |
getExtraPolatedPos()
Returns the extrapolated position.
|
int |
getExtraPolatedVelocity()
Returns the extrapolated Velocity [km/h].
|
short |
getFix() |
int |
getGeoidSep()
Returns the applied Geoid separation [m].
|
GeoPosition |
getGPSPosition()
Returns the current position.
|
Position |
getGPSPositionMerc()
Returns the current position in format
CoordinateSystem.MERCATOR .
. |
short |
getNoSats()
Returns the number of satellites used for the fix.
|
short |
getNoSatsInView()
Returns the number of satellites in view.
|
int |
getQuality()
Returns the quality of the signal in percent, i.e. 0 for lowest, 100 for
best precision.
|
java.sql.Time |
getTime()
Returns a timestamp with the following information:
Time of fix [Hour of day * 1000000 + minute of hour * 10000 + second of minute * 100 + hundreds of a second].
|
int |
getVelocity()
Returns the velocity [km/h].
|
boolean |
isExtraPolated() |
void |
setAltitude(int altitude)
Sets the altitude [m] as reported from GPS.
|
void |
setCourse(int course)
Sets the navigation direction ([0..360[ 0=East, 90=North).
|
void |
setDate(java.util.Calendar date)
Sets the date of the given
Calendar as Gps date. |
void |
setDate(int date) |
void |
setDateAndTime(java.util.Calendar dateTime)
Sets the date and time of the Gps data by the given
Calendar object. |
void |
setExtraPolatedCourse(int extraPolatedCourse)
Sets the extrapolated Navigation direction ([0..360[ 0=East, 90=North).
|
void |
setExtraPolatedPos(Position extraPolatedPos)
Sets the extrapolated position.
|
void |
setExtraPolatedVelocity(int extraPolatedVelocity)
Sets the extrapolated Velocity [km/h].
|
void |
setFix(short fix)
Sets the fix information.
0 if GPS device has no fix,
>0 for a valid fix: 1=GPS (inkl. 2d/3d),
2=differential GPS (DGPS),
3= dead reckoning mode (DR),
4=unknown
|
void |
setGeoidSep(int geoidSep)
Sets the applied Geoid separation [m].
|
void |
setGPSPosition(GeoPosition gpsPosition)
Sets the GeoPosition.
|
void |
setGPSPositionMerc(Position gpsPositionMerc)
Sets the current position (Mercator).
|
void |
setIsExtraPolated(boolean isExtraPolated)
Sets whether the information is based on (software) internal extrapolation.
|
void |
setNoSats(short noSats)
Sets the number of satellites used for the fix.
|
void |
setNoSatsInView(short noSatsInView)
Sets the number of satellites in view.
|
void |
setQuality(int quality)
Sets the quality of the signal in percent, i.e. 0 for lowest, 100 for best
precision.
|
void |
setTime(java.util.Calendar time)
Sets the time of the given
Calendar as Gps time. |
void |
setTime(int time) |
void |
setVelocity(int velocity)
Sets the velocity [km/h].
|
java.lang.String |
toString() |
protected long jniCPtr
protected boolean jniCMemOwn
public com.ptvag.navigation.sdk.NativeObject parent
public GPSData()
public GPSData(long cPtr, boolean cMemoryOwn)
public GeoPosition getGPSPosition()
public Position getGPSPositionMerc()
CoordinateSystem.MERCATOR
.
.CoordinateSystem.MERCATOR
.public int getAltitude()
public int getVelocity()
public int getCourse()
public int getQuality()
public short getNoSats()
public java.util.Date getDate()
public java.sql.Time getTime()
public void setGPSPosition(GeoPosition gpsPosition)
gpsPosition
- the GeoPosition to set.public void setGPSPositionMerc(Position gpsPositionMerc)
gpsPositionMerc
- the current position (Mercator) to set.public void setAltitude(int altitude)
altitude
- the altitude [m] as reported from GPS to set.public void setVelocity(int velocity)
velocity
- to set.public void setCourse(int course)
course
- the navigation direction to set.public void setQuality(int quality)
quality
- the quality of the signalpublic void setNoSats(short noSats)
noSats
- the number of satellites.public short getFix()
public void setFix(short fix)
fix
- the fix information to set.public void setDateAndTime(java.util.Calendar dateTime)
Calendar
object.
To set the date and time the methods setDate(Calendar)
and
setTime(Calendar)
are called.dateTime
- The Calendar object which contains the date and time information.public void setDate(java.util.Calendar date)
Calendar
as Gps date. The Gps date is calculated by the formula:
gps date = day of month * 10000 + month of year * 100 + (year>=2000) ? (year-2000) : (year-1990).date
- The date as Calendar object.public void setTime(java.util.Calendar time)
Calendar
as Gps time. The Gps time is calculated by the formula:
gps time = hour of day * 1000000 + minute of hour * 10000 + second of minute * 100 + hundreds of a second.time
- The time as Calendar object.public int getGeoidSep()
public void setGeoidSep(int geoidSep)
geoidSep
- the applied Geoid separation to setpublic short getNoSatsInView()
public void setNoSatsInView(short noSatsInView)
noSatsInView
- the number of satellites in view to set.public boolean isExtraPolated()
public void setIsExtraPolated(boolean isExtraPolated)
isExtraPolated
- the information is based on (software) internal extrapolation.public Position getExtraPolatedPos()
public void setExtraPolatedPos(Position extraPolatedPos)
extraPolatedPos
- the extrapolated position to set.public int getExtraPolatedVelocity()
public void setExtraPolatedVelocity(int extraPolatedVelocity)
extraPolatedVelocity
- the extrapolated Velocity to set.public int getExtraPolatedCourse()
public void setExtraPolatedCourse(int extraPolatedCourse)
extraPolatedCourse
- the extrapolated Navigation direction to set.public java.lang.String toString()
toString
in class java.lang.Object
public void setTime(int time)
public void setDate(int date)
public static long getCPtr(com.ptvag.navigation.sdk.NativeObject obj)
protected void finalize() throws java.lang.Throwable
finalize
in class java.lang.Object
java.lang.Throwable
public void delete()