public class StepHandlerMultiplexer extends Object implements OrekitStepHandler
OrekitStepHandler instances into one.| Constructor and Description |
|---|
StepHandlerMultiplexer()
Simple constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(double h,
OrekitFixedStepHandler handler)
Add a handler for fixed size step.
|
void |
add(OrekitStepHandler handler)
Add a handler for variable size step.
|
void |
clear()
Remove all handlers managed by this multiplexer.
|
void |
finish(SpacecraftState finalState)
Finalize propagation.
|
List<OrekitStepHandler> |
getHandlers()
Get an unmodifiable view of all handlers.
|
void |
handleStep(OrekitStepInterpolator interpolator)
Handle the current step.
|
void |
init(SpacecraftState s0,
AbsoluteDate t)
Initialize step handler at the start of a propagation.
|
void |
remove(OrekitFixedStepHandler handler)
Remove a handler.
|
void |
remove(OrekitStepHandler handler)
Remove a handler.
|
public void add(OrekitStepHandler handler)
If propagation is ongoing (i.e. global init already called and global finish not called
yet), then the local OrekitStepHandler.init method of the added handler will be called with the last
known state, so the handler starts properly.
handler - step handler to addpublic void add(double h,
OrekitFixedStepHandler handler)
If propagation is ongoing (i.e. global init already called and global finish not called
yet), then the local OrekitFixedStepHandler.init method of the added handler will be called with the
last known state, so the handler starts properly.
h - fixed stepsize (s)handler - handler called at the end of each finalized steppublic List<OrekitStepHandler> getHandlers()
Note that if fixed step handlers have
been add(double, OrekitFixedStepHandler), then they will
show up wrapped within step normalizers.
public void remove(OrekitStepHandler handler)
If propagation is ongoing (i.e. global init already called and global finish not called
yet), then the local OrekitStepHandler.finish method of the removed handler will be called with the last
known state, so the handler stops properly.
handler - step handler to removepublic void remove(OrekitFixedStepHandler handler)
If propagation is ongoing (i.e. global init already called and global finish not called
yet), then the local OrekitFixedStepHandler.finish method of the removed handler will be called with the
last known state, so the handler stops properly.
handler - step handler to removepublic void clear()
If propagation is ongoing (i.e. global init already called and global finish not called
yet), then the local OrekitStepHandler.finish and OrekitFixedStepHandler.finish methods of the removed handlers will be called with the
last known state, so the handlers stop properly.
public void init(SpacecraftState s0, AbsoluteDate t)
This method is called once at the start of the propagation. It may be used by the step handler to initialize some internal data if needed.
The default method does nothing
init in interface OrekitStepHandlers0 - initial statet - target time for the integrationpublic void handleStep(OrekitStepInterpolator interpolator)
handleStep in interface OrekitStepHandlerinterpolator - interpolator set up for the current steppublic void finish(SpacecraftState finalState)
finish in interface OrekitStepHandlerfinalState - state at propagation endCopyright © 2002-2021 CS GROUP. All rights reserved.