org.orekit.propagation.events
public class DateDetector extends AbstractReconfigurableDetector<DateDetector> implements TimeStamped
This class finds date events (i.e. occurrence of some predefined dates).
As of version 5.1, it is an enhanced date detector:
DateDetector(double, double, TimeStamped...))addEventDate(AbsoluteDate))The gap between the added dates must be more than the maxCheck.
The default implementation behavior is to stop
propagation at the first event date occurrence. This can be changed by calling
AbstractReconfigurableDetector.withHandler(EventHandler) after construction.
Propagator.addEventDetector(EventDetector),
Serialized FormEventDetector.ActionDEFAULT_MAX_ITER, DEFAULT_MAXCHECK, DEFAULT_THRESHOLD| Constructor and Description |
|---|
DateDetector(AbsoluteDate target)
Build a new instance.
|
DateDetector(double maxCheck,
double threshold,
TimeStamped... dates)
Build a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addEventDate(AbsoluteDate target)
Add an event date.
|
protected DateDetector |
create(double newMaxCheck,
double newThreshold,
int newMaxIter,
EventHandler<DateDetector> newHandler)
Build a new instance.
|
double |
g(SpacecraftState s)
Compute the value of the switching function.
|
AbsoluteDate |
getDate()
Get the current event date according to the propagator.
|
convert, convert, eventOccurred, getHandler, resetState, withHandler, withMaxCheck, withMaxIter, withThresholdgetMaxCheckInterval, getMaxIterationCount, getThreshold, initpublic DateDetector(double maxCheck,
double threshold,
TimeStamped... dates)
First event dates are set here, but others can be
added later with addEventDate(AbsoluteDate).
maxCheck - maximum checking interval (s)threshold - convergence threshold (s)dates - list of event datesaddEventDate(AbsoluteDate)public DateDetector(AbsoluteDate target)
This constructor is dedicated to single date detection.
max check interval is set to 1.0e10, so almost
no other date can be added. Tolerance is set to 1.0e-9.
target - target dateaddEventDate(AbsoluteDate)protected DateDetector create(double newMaxCheck, double newThreshold, int newMaxIter, EventHandler<DateDetector> newHandler)
create in class AbstractReconfigurableDetector<DateDetector>newMaxCheck - maximum checking interval (s)newThreshold - convergence threshold (s)newMaxIter - maximum number of iterations in the event time searchnewHandler - event handler to call at event occurrencespublic double g(SpacecraftState s) throws OrekitException
g in interface EventDetectorg in class AbstractDetectors - the current state information: date, kinematics, attitudeOrekitException - if some specific error occurspublic AbsoluteDate getDate()
getDate in interface TimeStampedpublic void addEventDate(AbsoluteDate target) throws IllegalArgumentException
The date to add must be:
target - target dateIllegalArgumentException - if the date is too close from already defined intervalDateDetector(double, double, TimeStamped...)Copyright © 2002–2015 CS Syst?mes d'Information. All rights reserved.