public abstract class AbstractMain extends Object implements ISimulationControl, org.osgi.framework.BundleActivator
| Constructor and Description |
|---|
AbstractMain() |
| Modifier and Type | Method and Description |
|---|---|
Throwable |
getErrorThrowable()
Returns an exception which caused the simulation to terminate in case of simulation errors as
indicated by the
SimuComResult returned by the startSimulation method |
SimuComModel |
getModel() |
SimuComStatus |
getStatus()
Retrieve an object containing the status of this simulation.
|
void |
prepareSimulation(AbstractSimulationConfig config,
IStatusObserver observer,
boolean isRemoteRun)
Prepare a simulation run
|
void |
start(org.osgi.framework.BundleContext context) |
SimulationResult |
startSimulation(AbstractSimulationConfig config,
IStatusObserver observer,
boolean isRemoteRun)
Start a simulation run
|
void |
stop(org.osgi.framework.BundleContext context) |
void |
stopSimulation()
Cancels a running simulation by disallowing the generation of new simulation events
|
public void start(org.osgi.framework.BundleContext context)
throws Exception
start in interface org.osgi.framework.BundleActivatorExceptionpublic void stop(org.osgi.framework.BundleContext context)
throws Exception
stop in interface org.osgi.framework.BundleActivatorExceptionpublic SimuComModel getModel()
public Throwable getErrorThrowable()
ISimulationControlSimuComResult returned by the startSimulation methodgetErrorThrowable in interface ISimulationControlpublic void prepareSimulation(AbstractSimulationConfig config, IStatusObserver observer, boolean isRemoteRun)
ISimulationControlprepareSimulation in interface ISimulationControlconfig - The configuration object which sets many simulation parameters like stop
conditions, storage location, etc.observer - An observer which gets notifications on the simulation progressisRemoteRun - If true, the simulation uses an own, temporary result store instead of the
sensorfactory storage passed in the simulation parameter object. Use this for
remote simulation docks which do not have access to the local sensor factory
storagespublic SimulationResult startSimulation(AbstractSimulationConfig config, IStatusObserver observer, boolean isRemoteRun)
ISimulationControlstartSimulation in interface ISimulationControlconfig - The configuration object which sets many simulation parameters like stop
conditions, storage location, etc.observer - An observer which gets notifications on the simulation progressisRemoteRun - If true, the simulation uses an own, temporary result store instead of the
sensorfactory storage passed in the simulation parameter object. Use this for
remote simulation docks which do not have access to the local sensor factory
storagespublic void stopSimulation()
ISimulationControlstopSimulation in interface ISimulationControlpublic SimuComStatus getStatus()
ISimulationControlgetStatus in interface ISimulationControlSimuComStatus object containing the simulation status