Package gaiasky.util.coord
Class TimedOrbitCoordinates
java.lang.Object
gaiasky.util.coord.TimedOrbitCoordinates
- All Implemented Interfaces:
IBodyCoordinates
Composition of
IBodyCoordinates
that contains a start and end time of validity.-
Field Summary
FieldsModifier and TypeFieldDescriptionStart and end times of these coordinates.protected static final Logger.Log
com.badlogic.ashley.core.Entity
Parent entity for this orbit, if any.Parent object for this orbit.Start and end times of these coordinates. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
doneLoading
(Object... params) Initializes the coordinates objectgetCopy()
Gets a copy of this coordinates object.getEclipticCartesianCoordinates
(Instant instant, Vector3b out) Gets ecliptic cartesian coordinates for the given date.getEclipticSphericalCoordinates
(Instant instant, Vector3b out) Returns the ecliptic coordinates of the body in the out vector for the given date.getEquatorialCartesianCoordinates
(Instant instant, Vector3b out) Gets equatorial cartesian coordinates for the given date.boolean
Is this timed orbit coordinates instance in its validity period with regard to the given time?void
void
void
void
void
updateReferences
(Map<String, com.badlogic.ashley.core.Entity> index) Update the references in this coordinates object with the given index.
-
Field Details
-
logger
-
coordinates
-
start
Start and end times of these coordinates. -
end
Start and end times of these coordinates. -
parentName
Parent object for this orbit. This is useful when the new orbit changes the reference system. -
parent
public com.badlogic.ashley.core.Entity parentParent entity for this orbit, if any.
-
-
Constructor Details
-
TimedOrbitCoordinates
public TimedOrbitCoordinates()
-
-
Method Details
-
setParent
-
setStart
-
setEnd
-
setCoordinates
-
isValid
Is this timed orbit coordinates instance in its validity period with regard to the given time?- Parameters:
t
- The time to check.- Returns:
- True if this timed coordinates object is valid, false otherwise.
-
doneLoading
Description copied from interface:IBodyCoordinates
Initializes the coordinates object- Specified by:
doneLoading
in interfaceIBodyCoordinates
- Parameters:
params
- The parameter objects.
-
getEclipticSphericalCoordinates
Description copied from interface:IBodyCoordinates
Returns the ecliptic coordinates of the body in the out vector for the given date.- Specified by:
getEclipticSphericalCoordinates
in interfaceIBodyCoordinates
- Parameters:
instant
- The instant.out
- The out vector with the ecliptic coordinates in internal units.- Returns:
- The out vector for chaining.
-
getEclipticCartesianCoordinates
Description copied from interface:IBodyCoordinates
Gets ecliptic cartesian coordinates for the given date.- Specified by:
getEclipticCartesianCoordinates
in interfaceIBodyCoordinates
- Parameters:
instant
- The instant.out
- The out vector where the ecliptic cartesian coordinates will be.- Returns:
- The out vector for chaining, or null if the date is out of range, in case of non-elliptical orbits such as Gaia.
-
getEquatorialCartesianCoordinates
Description copied from interface:IBodyCoordinates
Gets equatorial cartesian coordinates for the given date.- Specified by:
getEquatorialCartesianCoordinates
in interfaceIBodyCoordinates
- Parameters:
instant
- The instant.out
- The out vector where the equatorial cartesian coordinates will be.- Returns:
- The out vector for chaining, or null if the date is out of range, in case of non-elliptical orbits such as Gaia.
-
updateReferences
Description copied from interface:IBodyCoordinates
Update the references in this coordinates object with the given index.- Specified by:
updateReferences
in interfaceIBodyCoordinates
- Parameters:
index
- The index to use.
-
getCopy
Description copied from interface:IBodyCoordinates
Gets a copy of this coordinates object.- Specified by:
getCopy
in interfaceIBodyCoordinates
- Returns:
- The copy.
-