Class SingleDateEventFunction
- java.lang.Object
-
- org.orekit.propagation.events.functions.SingleDateEventFunction
-
- All Implemented Interfaces:
EventFunction,TimeShiftable<SingleDateEventFunction>,TimeStamped
public class SingleDateEventFunction extends Object implements EventFunction, TimeStamped, TimeShiftable<SingleDateEventFunction>
Class representing single date detection. It is negative before the epoch.- Since:
- 14.0
- Author:
- Romain Serra
-
-
Constructor Summary
Constructors Constructor Description SingleDateEventFunction(AbsoluteDate date)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleandependsOnTimeOnly()Method returning true if and only if the event function does not depend on dependent variables, just the independent one i.e. time.AbsoluteDategetDate()Get the date.SingleDateEventFunctionshiftedBy(double dt)Get a time-shifted instance.SingleDateEventFunctionshiftedBy(TimeOffset dt)Get a time-shifted instance.<T extends CalculusFieldElement<T>>
Tvalue(FieldSpacecraftState<T> fieldState)Evaluate Field function.doublevalue(SpacecraftState state)Evaluate function.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.orekit.propagation.events.functions.EventFunction
dependsOnMainVariablesOnly
-
Methods inherited from interface org.orekit.time.TimeStamped
durationFrom
-
-
-
-
Constructor Detail
-
SingleDateEventFunction
public SingleDateEventFunction(AbsoluteDate date)
Constructor.- Parameters:
date- event date
-
-
Method Detail
-
value
public double value(SpacecraftState state)
Description copied from interface:EventFunctionEvaluate function.- Specified by:
valuein interfaceEventFunction- Parameters:
state- spacecraft state- Returns:
- value
-
value
public <T extends CalculusFieldElement<T>> T value(FieldSpacecraftState<T> fieldState)
Description copied from interface:EventFunctionEvaluate Field function. By default, calls the non-Field version. This is suitable for detection but not be for applications like automatic differentiation, where a proper implementation should be used instead.- Specified by:
valuein interfaceEventFunction- Type Parameters:
T- field type- Parameters:
fieldState- spacecraft state- Returns:
- value
-
dependsOnTimeOnly
public boolean dependsOnTimeOnly()
Description copied from interface:EventFunctionMethod returning true if and only if the event function does not depend on dependent variables, just the independent one i.e. time. This information is used for performance in propagation and derivatives correction with switches in the dynamics.- Specified by:
dependsOnTimeOnlyin interfaceEventFunction- Returns:
- flag
-
getDate
public AbsoluteDate getDate()
Description copied from interface:TimeStampedGet the date.- Specified by:
getDatein interfaceTimeStamped- Returns:
- date attached to the object
-
shiftedBy
public SingleDateEventFunction shiftedBy(double dt)
Description copied from interface:TimeShiftableGet a time-shifted instance.- Specified by:
shiftedByin interfaceTimeShiftable<SingleDateEventFunction>- Parameters:
dt- time shift in seconds- Returns:
- a new instance, shifted with respect to instance (which is not changed)
-
shiftedBy
public SingleDateEventFunction shiftedBy(TimeOffset dt)
Description copied from interface:TimeShiftableGet a time-shifted instance.- Specified by:
shiftedByin interfaceTimeShiftable<SingleDateEventFunction>- Parameters:
dt- time shift- Returns:
- a new instance, shifted with respect to instance (which is not changed)
-
-