public abstract class AbstractWrappableSimulation extends Object implements WrappableSimulation, Serializable
Copyright (c) 2013-2017 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
$LastChangedDate: 2017-04-29 12:51:08 +0200 (Sat, 29 Apr 2017) $, @version $Revision: 3570 $, by $Author: averbraeck $,
initial version Jun 18, 2015
Modifier and Type | Field and Description |
---|---|
protected ArrayList<org.opentrafficsim.base.modelproperties.AbstractProperty<?>> |
properties
The properties exhibited by this simulation.
|
Constructor and Description |
---|
AbstractWrappableSimulation() |
Modifier and Type | Method and Description |
---|---|
protected SimpleSimulator |
buildSimpleSimulator(org.djunits.value.vdouble.scalar.Time startTime,
org.djunits.value.vdouble.scalar.Duration warmupPeriod,
org.djunits.value.vdouble.scalar.Duration runLength,
OTSModelInterface model)
Build the simulator.
|
SimpleSimulator |
buildSimulator(org.djunits.value.vdouble.scalar.Time startTime,
org.djunits.value.vdouble.scalar.Duration warmupPeriod,
org.djunits.value.vdouble.scalar.Duration runLength,
ArrayList<org.opentrafficsim.base.modelproperties.AbstractProperty<?>> userModifiedProperties)
Build the simulation.
|
ArrayList<org.opentrafficsim.base.modelproperties.AbstractProperty<?>> |
getProperties()
Retrieve a list of visible properties of the simulation.
|
protected abstract OTSModelInterface |
makeModel() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
description, shortName
protected ArrayList<org.opentrafficsim.base.modelproperties.AbstractProperty<?>> properties
protected SimpleSimulator buildSimpleSimulator(org.djunits.value.vdouble.scalar.Time startTime, org.djunits.value.vdouble.scalar.Duration warmupPeriod, org.djunits.value.vdouble.scalar.Duration runLength, OTSModelInterface model) throws nl.tudelft.simulation.dsol.SimRuntimeException, NamingException, org.opentrafficsim.base.modelproperties.PropertyException
startTime
- Time; the start timewarmupPeriod
- Duration; the warm up periodrunLength
- Duration; the duration of the simulation / animationmodel
- OTSModelInterface; the simulation modelnl.tudelft.simulation.dsol.SimRuntimeException
- on ???NamingException
- when context for the animation cannot be createdorg.opentrafficsim.base.modelproperties.PropertyException
- when one of the user modified properties has the empty string as keypublic SimpleSimulator buildSimulator(org.djunits.value.vdouble.scalar.Time startTime, org.djunits.value.vdouble.scalar.Duration warmupPeriod, org.djunits.value.vdouble.scalar.Duration runLength, ArrayList<org.opentrafficsim.base.modelproperties.AbstractProperty<?>> userModifiedProperties) throws nl.tudelft.simulation.dsol.SimRuntimeException, NamingException, OTSSimulationException, org.opentrafficsim.base.modelproperties.PropertyException
buildSimulator
in interface WrappableSimulation
startTime
- Time; the start time of the simulationwarmupPeriod
- Duration; the warm up period of the simulation (use new Duration(0, SECOND) if you don't know what
this is)runLength
- Duration; the duration of the simulationuserModifiedProperties
- ArrayList<AbstractProperty<?>>; the (possibly user-modified) properties. This list must
contain all the properties returned by getProperties(); any additional properties may be ignorednl.tudelft.simulation.dsol.SimRuntimeException
- on ???NamingException
- when context for the animation cannot be createdOTSSimulationException
- when the construction of the simulation, the control panel, the animation, or the charts
failsorg.opentrafficsim.base.modelproperties.PropertyException
- when one of the user modified properties has the empty string as keyprotected abstract OTSModelInterface makeModel() throws OTSSimulationException
OTSSimulationException
- when the construction of the model failspublic final ArrayList<org.opentrafficsim.base.modelproperties.AbstractProperty<?>> getProperties()
getProperties
in interface WrappableSimulation
Copyright © 2014–2017 Delft University of Technology. All rights reserved.