Package org.opentrafficsim.demo.steering
Class SteeringSimulation
java.lang.Object
org.opentrafficsim.swing.script.AbstractSimulationScript
org.opentrafficsim.demo.steering.SteeringSimulation
- All Implemented Interfaces:
java.util.EventListener
,EventListenerInterface
,Checkable
public class SteeringSimulation extends AbstractSimulationScript
Simulation script for steering functionality.
Copyright (c) 2013-2019 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
- Version:
- $Revision$, $LastChangedDate$, by $Author$, initial version 8 jan. 2019
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
-
Constructor Summary
Constructors Modifier Constructor Description protected
SteeringSimulation()
Constructor. -
Method Summary
Modifier and Type Method Description static void
main(java.lang.String... args)
Start a simulation.protected OTSRoadNetwork
setupSimulation(OTSSimulatorInterface sim)
Sets up the simulation based on provided properties.Methods inherited from class org.opentrafficsim.swing.script.AbstractSimulationScript
addTabs, animateNetwork, check, getGtuColorer, getNetwork, getSeed, getSimulationTime, getSimulator, getStartTime, getWarmupTime, isAutorun, notify, onSimulationEnd, setAnimationToggles, setGtuColorer, setupDemo, start
-
Constructor Details
-
SteeringSimulation
protected SteeringSimulation()Constructor.
-
-
Method Details
-
main
public static void main(java.lang.String... args)Start a simulation.- Parameters:
args
- String...; command line arguments
-
setupSimulation
Sets up the simulation based on provided properties. Properties can be obtained withgetProperty()
. Setting up a simulation should at least create a network and some demand. Additionally this may setup traffic control, sampling, etc.- Specified by:
setupSimulation
in classAbstractSimulationScript
- Parameters:
sim
- OTSSimulatorInterface; simulator- Returns:
- OTSRoadNetwork; network
- Throws:
java.lang.Exception
- on any exception
-