Class GeneratorPositions.RoadPosition.BySpeed
- java.lang.Object
-
- org.opentrafficsim.road.gtu.generator.GeneratorPositions.RoadPosition.BySpeed
-
- All Implemented Interfaces:
GeneratorPositions.RoadPosition
- Enclosing interface:
- GeneratorPositions.RoadPosition
public static class GeneratorPositions.RoadPosition.BySpeed extends Object implements GeneratorPositions.RoadPosition
Road position based on desired speed.Copyright (c) 2013-2020 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 15 jan. 2018
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.opentrafficsim.road.gtu.generator.GeneratorPositions.RoadPosition
GeneratorPositions.RoadPosition.BySpeed, GeneratorPositions.RoadPosition.ByValue
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
double
getValue(Speed desiredSpeed)
Returns the road position (0.0 = right, 1.0 = left).int
hashCode()
-
-
-
Method Detail
-
getValue
public double getValue(Speed desiredSpeed)
Returns the road position (0.0 = right, 1.0 = left).- Specified by:
getValue
in interfaceGeneratorPositions.RoadPosition
- Parameters:
desiredSpeed
- Speed; desired speed at the generator- Returns:
- road position (0.0 = right, 1.0 = left)
-
-