public class SplitFraction extends Object
Copyright (c) 2013-2018 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
Constructor and Description |
---|
SplitFraction(org.opentrafficsim.core.network.Node node,
Interpolation interpolation,
nl.tudelft.simulation.jstats.streams.StreamInterface random,
nl.tudelft.simulation.dsol.simulators.DEVSSimulatorInterface.TimeDoubleUnit simulator)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addFraction(org.opentrafficsim.core.network.Link link,
double fraction)
Add fraction to link, this will apply to
GTUType.ALL and all time. |
void |
addFraction(org.opentrafficsim.core.network.Link link,
org.djunits.value.vdouble.vector.DurationVector time,
double[] fraction)
Add fraction to link over time, this will apply to
GTUType.ALL . |
void |
addFraction(org.opentrafficsim.core.network.Link link,
org.opentrafficsim.core.gtu.GTUType gtuType,
double fraction)
Add fraction to link for gtu type, this will apply to all time.
|
void |
addFraction(org.opentrafficsim.core.network.Link link,
org.opentrafficsim.core.gtu.GTUType gtuType,
org.djunits.value.vdouble.vector.DurationVector time,
double[] fraction)
Add fraction to link over time for gtu type.
|
org.opentrafficsim.core.network.Link |
draw(org.opentrafficsim.core.gtu.GTUType gtuType)
Draw next link based on split fractions.
|
boolean |
equals(Object obj) |
int |
hashCode() |
String |
toString() |
public SplitFraction(org.opentrafficsim.core.network.Node node, Interpolation interpolation, nl.tudelft.simulation.jstats.streams.StreamInterface random, nl.tudelft.simulation.dsol.simulators.DEVSSimulatorInterface.TimeDoubleUnit simulator)
node
- nodeinterpolation
- interpolationrandom
- random streamsimulator
- simulatorpublic void addFraction(org.opentrafficsim.core.network.Link link, double fraction)
GTUType.ALL
and all time.link
- linkfraction
- fractionpublic void addFraction(org.opentrafficsim.core.network.Link link, org.opentrafficsim.core.gtu.GTUType gtuType, double fraction)
link
- linkgtuType
- gtu typefraction
- fractionpublic void addFraction(org.opentrafficsim.core.network.Link link, org.djunits.value.vdouble.vector.DurationVector time, double[] fraction)
GTUType.ALL
.link
- linktime
- timefraction
- fractionpublic void addFraction(org.opentrafficsim.core.network.Link link, org.opentrafficsim.core.gtu.GTUType gtuType, org.djunits.value.vdouble.vector.DurationVector time, double[] fraction)
link
- linkgtuType
- gtu typetime
- timefraction
- fractionpublic org.opentrafficsim.core.network.Link draw(org.opentrafficsim.core.gtu.GTUType gtuType)
gtuType
- gtuTypeCopyright © 2014–2018 Delft University of Technology. All rights reserved.