Class AttitudesSwitcher.InstantaneousSwitch
- All Implemented Interfaces:
DetectorModifier,EventDetector,EventHandler
- Enclosing class:
AttitudesSwitcher
-
Method Summary
Modifier and TypeMethodDescriptioneventOccurred(SpacecraftState s, EventDetector detector, boolean increasing) Handle an event.Get the wrapped detector.protected AttitudeProviderProtected getter for future attitude provider.Get the handler.protected AttitudeProvidergetPast()Protected getter for past attitude provider.protected AttitudeSwitchHandlerProtected getter for switch handle.voidinit(SpacecraftState s0, AbsoluteDate t) Initialize event detector at the start of a propagation.protected booleanProtected getter for switch-on-decrease flag.protected booleanProtected getter for switch-on-increase flag.resetState(EventDetector detector, SpacecraftState oldState) Reset the state prior to continue propagation.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.orekit.propagation.events.DetectorModifier
finish, g, getDetectionSettings, getEventFunction, resetMethods inherited from interface org.orekit.propagation.events.EventDetector
getMaxCheckInterval, getMaxIterationCount, getThresholdMethods inherited from interface org.orekit.propagation.events.handlers.EventHandler
finish, init
-
Method Details
-
init
Initialize event detector at the start of a propagation.This method is called once at the start of the propagation. It may be used by the event handler to initialize some internal data if needed.
The default implementation initializes the handler.
- Parameters:
s0- initial statet- target time for the integration
-
eventOccurred
Handle an event.- Parameters:
s- SpaceCraft state to be used in the evaluationdetector- object with appropriate type that can be used in determining correct return stateincreasing- with the event occurred in an "increasing" or "decreasing" slope direction- Returns:
- the Action that the calling detector should pass back to the evaluation system
-
getDetector
Get the wrapped detector.- Specified by:
getDetectorin interfaceDetectorModifier- Returns:
- wrapped detector
-
getSwitchHandler
Protected getter for switch handle.- Returns:
- switch handler
-
getFuture
Protected getter for future attitude provider.- Returns:
- future provider
-
getPast
Protected getter for past attitude provider.- Returns:
- pas provider
-
isSwitchOnDecrease
protected boolean isSwitchOnDecrease()Protected getter for switch-on-decrease flag.- Returns:
- flag
-
isSwitchOnIncrease
protected boolean isSwitchOnIncrease()Protected getter for switch-on-increase flag.- Returns:
- flag
-
getHandler
Get the handler.- Specified by:
getHandlerin interfaceDetectorModifier- Specified by:
getHandlerin interfaceEventDetector- Returns:
- event handler to call at event occurrences
-
resetState
Reset the state prior to continue propagation.This method is called after the step handler has returned and before the next step is started, but only when
EventHandler.eventOccurred(org.orekit.propagation.SpacecraftState, org.orekit.propagation.events.EventDetector, boolean)has itself returned theAction.RESET_STATEindicator. It allows the user to reset the state for the next step, without perturbing the step handler of the finishing step. If theEventHandler.eventOccurred(org.orekit.propagation.SpacecraftState, org.orekit.propagation.events.EventDetector, boolean)never returns theAction.RESET_STATEindicator, this function will never be called, and it is safe to simply return null.The default implementation simply return its argument.
- Specified by:
resetStatein interfaceEventHandler- Parameters:
detector- object with appropriate type that can be used in determining correct return stateoldState- old state- Returns:
- new state
-