Class TrajectoryStateHistoryMetadata
- java.lang.Object
-
- org.orekit.files.ccsds.section.CommentsContainer
-
- org.orekit.files.ccsds.ndm.odm.ocm.TrajectoryStateHistoryMetadata
-
- All Implemented Interfaces:
Section
public class TrajectoryStateHistoryMetadata extends CommentsContainer
Metadata for trajectory state history.- Since:
- 11.0
- Author:
- Luc Maisonobe
-
-
Field Summary
Fields Modifier and Type Field Description static int
DEFAULT_INTERPOLATION_DEGREE
Default interpolation degree.static InterpolationMethod
DEFAULT_INTERPOLATION_METHOD
Default interpolation method.
-
Constructor Summary
Constructors Constructor Description TrajectoryStateHistoryMetadata(AbsoluteDate epochT0, DataContext dataContext)
Simple constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description TrajectoryStateHistoryMetadata
copy(double version)
Copy the instance, making sure mandatory fields have been initialized.BodyFacade
getCenter()
Get the origin of reference frame.int
getInterpolationDegree()
Get the interpolation degree.InterpolationMethod
getInterpolationMethod()
Get the interpolation method to be used.String
getOrbAveraging()
Get type of averaging (Osculating, mean Brouwer, other.int
getOrbRevNum()
Get the integer orbit revolution number.int
getOrbRevNumBasis()
Get the basis for orbit revolution number.String
getPropagator()
Get the orbit propagator used to generate this trajectory.String
getTrajBasis()
Get basis of this trajectory state time history data.String
getTrajBasisID()
Get identification number of the orbit determination or simulation upon which this trajectory is based.AbsoluteDate
getTrajFrameEpoch()
Get epoch of thetrajectory reference frame
.String
getTrajID()
Get trajectory identification number.String
getTrajNextID()
Get identification number of next trajectory.String
getTrajPrevID()
Get identification number of previous trajectory.FrameFacade
getTrajReferenceFrame()
Get reference frame of the trajectory.OrbitElementsType
getTrajType()
Get trajectory element set type.List<Unit>
getTrajUnits()
Get trajectory element set units.AbsoluteDate
getUseableStartTime()
Get start of useable time span covered by ephemerides data, it may be necessary to allow for proper interpolation.AbsoluteDate
getUseableStopTime()
Get end of useable time span covered by ephemerides data, it may be necessary to allow for proper interpolation.static String
incrementTrajID(String original)
Increments a trajectory ID.void
setCenter(BodyFacade center)
Set the origin of reference frame.void
setInterpolationDegree(int interpolationDegree)
Set the interpolation degree.void
setInterpolationMethod(InterpolationMethod interpolationMethod)
Set the interpolation method to be used.void
setOrbAveraging(String orbAveraging)
Set type of averaging (Osculating, mean Brouwer, other.void
setOrbRevNum(int orbRevNum)
Set the integer orbit revolution number.void
setOrbRevNumBasis(int orbRevNumBasis)
Set the basis for orbit revolution number.void
setPropagator(String propagator)
Set the orbit propagator used to generate this trajectory.void
setTrajBasis(String trajBasis)
Set basis of this trajectory state time history data.void
setTrajBasisID(String trajBasisID)
Set identification number of the orbit determination or simulation upon which this trajectory is based.void
setTrajFrameEpoch(AbsoluteDate trajFrameEpoch)
Set epoch of thetrajectory reference frame
.void
setTrajID(String trajID)
Set trajectory identification number.void
setTrajNextID(String trajNextID)
Set identification number of next trajectory.void
setTrajPrevID(String trajPrevID)
Set identification number of previous trajectory.void
setTrajReferenceFrame(FrameFacade trajReferenceFrame)
Set reference frame of the trajectory.void
setTrajType(OrbitElementsType trajType)
Set trajectory element set type.void
setTrajUnits(List<Unit> trajUnits)
Set trajectory element set units.void
setUseableStartTime(AbsoluteDate useableStartTime)
Set start of useable time span covered by ephemerides data, it may be necessary to allow for proper interpolation.void
setUseableStopTime(AbsoluteDate useableStopTime)
Set end of useable time span covered by ephemerides data, it may be necessary to allow for proper interpolation.void
validate(double version)
Check is all mandatory entries have been initialized.-
Methods inherited from class org.orekit.files.ccsds.section.CommentsContainer
acceptComments, addComment, checkAllowed, checkNotNaN, checkNotNegative, checkNotNull, getComments, refuseFurtherComments, setComments
-
-
-
-
Field Detail
-
DEFAULT_INTERPOLATION_METHOD
public static final InterpolationMethod DEFAULT_INTERPOLATION_METHOD
Default interpolation method.- Since:
- 12.0
-
DEFAULT_INTERPOLATION_DEGREE
public static final int DEFAULT_INTERPOLATION_DEGREE
Default interpolation degree.- Since:
- 12.0
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
TrajectoryStateHistoryMetadata
public TrajectoryStateHistoryMetadata(AbsoluteDate epochT0, DataContext dataContext)
Simple constructor.- Parameters:
epochT0
- T0 epoch from file metadatadataContext
- data context
-
-
Method Detail
-
validate
public void validate(double version)
Check is all mandatory entries have been initialized.This method should throw an exception if some mandatory entries are missing or not compatible with version number.
- Specified by:
validate
in interfaceSection
- Overrides:
validate
in classCommentsContainer
- Parameters:
version
- format version
-
incrementTrajID
public static String incrementTrajID(String original)
Increments a trajectory ID.The trajectory blocks metadata contains three identifiers (
TRAJ_ID
,TRAJ_PREV_ID
,TRAJ_NEXT_ID
) that link the various blocks together. This helper method allows to update one identifier based on the value of another identifier. The update is performed by looking for an integer suffix at the end of theoriginal
identifier and incrementing it by one, taking care to use at least the same number of digits. If for example the original identifier is set totrajectory 037
, then the updated identifier will betrajectory 038
.This helper function is intended to be used by ephemeris generators like
EphemerisOcmWriter
andStreamingOcmWriter
, allowing users to call onlysetTrajBasisID(String)
in the trajectory metadata template. The ephemeris generators calltemplate.setTrajNextID(TrajectoryStateHistoryMetadata.incrementTrajID(template.getTrajID()))
before generating each trajectory block and call bothtemplate.setTrajPrevID(template.getTrajID()))
andtemplate.setTrajID(template.getTrajNextID()))
after having generated each block.- Parameters:
original
- original ID (may be null)- Returns:
- incremented ID, or null if original was null
-
getTrajID
public String getTrajID()
Get trajectory identification number.- Returns:
- trajectory identification number
-
setTrajID
public void setTrajID(String trajID)
Set trajectory identification number.- Parameters:
trajID
- trajectory identification number
-
getTrajPrevID
public String getTrajPrevID()
Get identification number of previous trajectory.- Returns:
- identification number of previous trajectory
-
setTrajPrevID
public void setTrajPrevID(String trajPrevID)
Set identification number of previous trajectory.- Parameters:
trajPrevID
- identification number of previous trajectory
-
getTrajNextID
public String getTrajNextID()
Get identification number of next trajectory.- Returns:
- identification number of next trajectory
-
setTrajNextID
public void setTrajNextID(String trajNextID)
Set identification number of next trajectory.- Parameters:
trajNextID
- identification number of next trajectory
-
getTrajBasis
public String getTrajBasis()
Get basis of this trajectory state time history data.- Returns:
- basis of this trajectory state time history data
-
setTrajBasis
public void setTrajBasis(String trajBasis)
Set basis of this trajectory state time history data.- Parameters:
trajBasis
- basis of this trajectory state time history data
-
getTrajBasisID
public String getTrajBasisID()
Get identification number of the orbit determination or simulation upon which this trajectory is based.- Returns:
- identification number of the orbit determination or simulation upon which this trajectory is based
-
setTrajBasisID
public void setTrajBasisID(String trajBasisID)
Set identification number of the orbit determination or simulation upon which this trajectory is based.- Parameters:
trajBasisID
- identification number of the orbit determination or simulation upon which this trajectory is based
-
getInterpolationMethod
public InterpolationMethod getInterpolationMethod()
Get the interpolation method to be used.- Returns:
- the interpolation method
-
setInterpolationMethod
public void setInterpolationMethod(InterpolationMethod interpolationMethod)
Set the interpolation method to be used.- Parameters:
interpolationMethod
- the interpolation method to be set
-
getInterpolationDegree
public int getInterpolationDegree()
Get the interpolation degree.- Returns:
- the interpolation degree
-
setInterpolationDegree
public void setInterpolationDegree(int interpolationDegree)
Set the interpolation degree.- Parameters:
interpolationDegree
- the interpolation degree to be set
-
getPropagator
public String getPropagator()
Get the orbit propagator used to generate this trajectory.- Returns:
- orbit propagator used to generate this trajectory
- Since:
- 11.2
-
setPropagator
public void setPropagator(String propagator)
Set the orbit propagator used to generate this trajectory.- Parameters:
propagator
- orbit propagator used to generate this trajectory- Since:
- 11.2
-
getCenter
public BodyFacade getCenter()
Get the origin of reference frame.- Returns:
- the origin of reference frame.
-
setCenter
public void setCenter(BodyFacade center)
Set the origin of reference frame.- Parameters:
center
- origin of reference frame to be set
-
getTrajReferenceFrame
public FrameFacade getTrajReferenceFrame()
Get reference frame of the trajectory.- Returns:
- reference frame of the trajectory
-
setTrajReferenceFrame
public void setTrajReferenceFrame(FrameFacade trajReferenceFrame)
Set reference frame of the trajectory.- Parameters:
trajReferenceFrame
- the reference frame to be set
-
getTrajFrameEpoch
public AbsoluteDate getTrajFrameEpoch()
Get epoch of thetrajectory reference frame
.- Returns:
- epoch of the
trajectory reference frame
-
setTrajFrameEpoch
public void setTrajFrameEpoch(AbsoluteDate trajFrameEpoch)
Set epoch of thetrajectory reference frame
.- Parameters:
trajFrameEpoch
- epoch of thetrajectory reference frame
-
getUseableStartTime
public AbsoluteDate getUseableStartTime()
Get start of useable time span covered by ephemerides data, it may be necessary to allow for proper interpolation.- Returns:
- the useable start time
-
setUseableStartTime
public void setUseableStartTime(AbsoluteDate useableStartTime)
Set start of useable time span covered by ephemerides data, it may be necessary to allow for proper interpolation.- Parameters:
useableStartTime
- the time to be set
-
getUseableStopTime
public AbsoluteDate getUseableStopTime()
Get end of useable time span covered by ephemerides data, it may be necessary to allow for proper interpolation.- Returns:
- the useable stop time
-
setUseableStopTime
public void setUseableStopTime(AbsoluteDate useableStopTime)
Set end of useable time span covered by ephemerides data, it may be necessary to allow for proper interpolation.- Parameters:
useableStopTime
- the time to be set
-
getOrbRevNum
public int getOrbRevNum()
Get the integer orbit revolution number.- Returns:
- integer orbit revolution number (-1 if not set)
-
setOrbRevNum
public void setOrbRevNum(int orbRevNum)
Set the integer orbit revolution number.- Parameters:
orbRevNum
- integer orbit revolution number
-
getOrbRevNumBasis
public int getOrbRevNumBasis()
Get the basis for orbit revolution number.This specifies if first launch/deployment is on orbit 0 or 1.
- Returns:
- basis for orbit revolution number (-1 if not set)
-
setOrbRevNumBasis
public void setOrbRevNumBasis(int orbRevNumBasis)
Set the basis for orbit revolution number.This specifies if first launch/deployment is on orbit 0 or 1.
- Parameters:
orbRevNumBasis
- basis for orbit revolution number
-
getOrbAveraging
public String getOrbAveraging()
Get type of averaging (Osculating, mean Brouwer, other.- Returns:
- type of averaging (Osculating, mean Brouwer, other)
-
setOrbAveraging
public void setOrbAveraging(String orbAveraging)
Set type of averaging (Osculating, mean Brouwer, other.- Parameters:
orbAveraging
- type of averaging (Osculating, mean Brouwer, other).
-
getTrajType
public OrbitElementsType getTrajType()
Get trajectory element set type.- Returns:
- trajectory element set type
-
setTrajType
public void setTrajType(OrbitElementsType trajType)
Set trajectory element set type.- Parameters:
trajType
- trajectory element set type
-
getTrajUnits
public List<Unit> getTrajUnits()
Get trajectory element set units.- Returns:
- trajectory element set units
-
setTrajUnits
public void setTrajUnits(List<Unit> trajUnits)
Set trajectory element set units.- Parameters:
trajUnits
- trajectory element set units
-
copy
public TrajectoryStateHistoryMetadata copy(double version)
Copy the instance, making sure mandatory fields have been initialized.Dates and orbit counter are not copied.
- Parameters:
version
- format version- Returns:
- a new copy
- Since:
- 12.0
-
-