Package org.opentrafficsim.core.dsol
Class OtsReplication
java.lang.Object
nl.tudelft.simulation.dsol.experiment.AbstractReplication<T>
nl.tudelft.simulation.dsol.experiment.SingleReplication<Duration>
org.opentrafficsim.core.dsol.OtsReplication
- All Implemented Interfaces:
Serializable,ReplicationInterface<Duration>,RunControlInterface<Duration>,Contextualized
Copyright (c) 2013-2023 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
- Author:
- Alexander Verbraeck
- See Also:
-
Field Summary
Fields inherited from class nl.tudelft.simulation.dsol.experiment.AbstractReplication
context, runControlFields inherited from interface nl.tudelft.simulation.dsol.experiment.ReplicationInterface
END_REPLICATION_EVENT, START_REPLICATION_EVENT, WARMUP_EVENT -
Constructor Summary
ConstructorsConstructorDescriptionOtsReplication(String id, Time startTime, Duration warmupPeriod, Duration runLength) Create a new OTSReplication. -
Method Summary
Modifier and TypeMethodDescriptiongetHistoryManager(OtsSimulatorInterface simulator) Returns the history manager.Return the absolute start time of the simulation.voidsetHistoryManager(HistoryManager historyManager) Set history manager.final StringtoString()Methods inherited from class nl.tudelft.simulation.dsol.experiment.SingleReplication
getRunControl, removeFromContext, setContextMethods inherited from class nl.tudelft.simulation.dsol.experiment.AbstractReplication
getContextMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface nl.tudelft.simulation.dsol.experiment.ReplicationInterface
getDescription, getEndSimTime, getId, getStartSimTime, getWarmupSimTime, setDescriptionMethods inherited from interface nl.tudelft.simulation.dsol.experiment.RunControlInterface
getEndTime, getRunLength, getStartTime, getWarmupPeriod, getWarmupTime
-
Constructor Details
-
OtsReplication
public OtsReplication(String id, Time startTime, Duration warmupPeriod, Duration runLength) throws NamingException Create a new OTSReplication.- Parameters:
id- String; id of the new OTSReplicationstartTime- Time; the start time of the new OTSReplicationwarmupPeriod- Duration; the warmup period of the new OTSReplicationrunLength- Duration; the run length of the new OTSReplication- Throws:
NamingException- when the context for the replication cannot be created
-
-
Method Details
-
getHistoryManager
Returns the history manager. If none was set, one is created coupled to the simulator using 0s of history and 10s clean-up time.- Parameters:
simulator- OtsSimulatorInterface; simulator- Returns:
- HistoryManager; history manager
-
setHistoryManager
Set history manager.- Parameters:
historyManager- HistoryManager; history manager to set
-
getStartTimeAbs
Return the absolute start time of the simulation.- Returns:
- Time; the absolute start time of the simulation
-
toString
- Overrides:
toStringin classAbstractReplication<Duration>
-