public class LaneBasedTemplateGTUType extends TemplateGTUType implements LaneBasedGTUCharacteristicsGenerator
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.
Constructor and Description |
---|
LaneBasedTemplateGTUType(GTUType gtuType,
Generator<Length> lengthGenerator,
Generator<Length> widthGenerator,
Generator<Speed> maximumSpeedGenerator,
LaneBasedStrategicalPlannerFactory<?> strategicalPlannerFactory,
Generator<Route> routeGenerator) |
Modifier and Type | Method and Description |
---|---|
LaneBasedGTUCharacteristics |
draw()
Generate the properties of the next GTU.
|
String |
toString() |
getGTUType
public LaneBasedTemplateGTUType(GTUType gtuType, Generator<Length> lengthGenerator, Generator<Length> widthGenerator, Generator<Speed> maximumSpeedGenerator, LaneBasedStrategicalPlannerFactory<?> strategicalPlannerFactory, Generator<Route> routeGenerator) throws NullPointerException
gtuType
- GTUType; The GTUType to make it identifiable.lengthGenerator
- Generator<Length>; Generator<Length> generator for the length of the GTU type
(parallel with driving direction).widthGenerator
- Generator<Length>; generator for the width of the GTU type (perpendicular to driving
direction).maximumSpeedGenerator
- Generator<Speed>; generator for the maximum speed of the GTU type (in the driving
direction).strategicalPlannerFactory
- LaneBasedStrategicalPlannerFactory<?>; Factory for the strategical planner (e.g.,
route determination)routeGenerator
- Generator<Route>; route generatorNullPointerException
- when one or more parameters are nullpublic final LaneBasedGTUCharacteristics draw() throws ProbabilityException, ParameterException
draw
in interface Generator<GTUCharacteristics>
draw
in interface LaneBasedGTUCharacteristicsGenerator
draw
in class TemplateGTUType
ProbabilityException
- when a generator is improperly configuredParameterException
- in case of a parameter problem.public String toString()
toString
in class TemplateGTUType
Copyright © 2014–2019 Delft University of Technology. All rights reserved.