Package org.orekit.time
Class GPSDate
- java.lang.Object
-
- org.orekit.time.GPSDate
-
- All Implemented Interfaces:
Serializable
,TimeStamped
public class GPSDate extends Object implements Serializable, TimeStamped
Container for date in GPS form.- Since:
- 9.3
- Author:
- Luc Maisonobe
- See Also:
AbsoluteDate
, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description GPSDate(int weekNumber, double milliInWeek)
Build an instance corresponding to a GPS date.GPSDate(AbsoluteDate date)
Build an instance from an absolute date.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AbsoluteDate
getDate()
Get the date.double
getMilliInWeek()
Get the number of milliseconds since week start.int
getWeekNumber()
Get the week number sinceGPS epoch
.
-
-
-
Constructor Detail
-
GPSDate
public GPSDate(int weekNumber, double milliInWeek)
Build an instance corresponding to a GPS date.GPS dates are provided as a week number starting at
GPS epoch
and as a number of milliseconds since week start.- Parameters:
weekNumber
- week number sinceGPS epoch
milliInWeek
- number of milliseconds since week start
-
GPSDate
public GPSDate(AbsoluteDate date)
Build an instance from an absolute date.- Parameters:
date
- absolute date to consider
-
-
Method Detail
-
getWeekNumber
public int getWeekNumber()
Get the week number sinceGPS epoch
.- Returns:
- week number since
GPS epoch
-
getMilliInWeek
public double getMilliInWeek()
Get the number of milliseconds since week start.- Returns:
- number of milliseconds since week start
-
getDate
public AbsoluteDate getDate()
Get the date.- Specified by:
getDate
in interfaceTimeStamped
- Returns:
- date attached to the object
-
-