Interface LaneBasedTacticalPlannerFactory<T extends LaneBasedTacticalPlanner>
- Type Parameters:
T
- class of the tactical planner generated
- All Superinterfaces:
ModelComponentFactory
- All Known Implementing Classes:
AbstractLaneBasedTacticalPlannerFactory
,LaneBasedCfLcTacticalPlannerFactory
,LaneBasedGtuFollowingTacticalPlannerFactory
,LmrsFactory
,ToledoFactory
public interface LaneBasedTacticalPlannerFactory<T extends LaneBasedTacticalPlanner>
extends ModelComponentFactory
A factory class is used to generate tactical planners as the tactical planner is state-full.
Copyright (c) 2013-2024 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
-
Method Summary
Modifier and TypeMethodDescriptioncreate
(LaneBasedGtu gtu) Creates a new tactical planner for the given GTU.default org.djunits.value.vdouble.scalar.Length
peekDesiredHeadway
(GtuType gtuType, org.djunits.value.vdouble.scalar.Speed speed, org.opentrafficsim.base.parameters.Parameters parameters) Peek to see the desired headway of the next GTU to be generated at the given speed.default org.djunits.value.vdouble.scalar.Speed
peekDesiredSpeed
(GtuType gtuType, org.djunits.value.vdouble.scalar.Speed speedLimit, org.djunits.value.vdouble.scalar.Speed maxGtuSpeed, org.opentrafficsim.base.parameters.Parameters parameters) Peek to see the desired speed of the next GTU to be generated at the given location.Methods inherited from interface org.opentrafficsim.road.gtu.lane.tactical.ModelComponentFactory
getParameters
-
Method Details
-
create
Creates a new tactical planner for the given GTU.- Parameters:
gtu
- LaneBasedGtu; GTU- Returns:
- tactical planner for the given GTU
- Throws:
GtuException
- if the gtu is not suitable in any way for the creation of the tactical planner
-
peekDesiredSpeed
default org.djunits.value.vdouble.scalar.Speed peekDesiredSpeed(GtuType gtuType, org.djunits.value.vdouble.scalar.Speed speedLimit, org.djunits.value.vdouble.scalar.Speed maxGtuSpeed, org.opentrafficsim.base.parameters.Parameters parameters) throws GtuException Peek to see the desired speed of the next GTU to be generated at the given location. The default implementation returnsnull
, at which point the GTU generator will use some other speed.- Parameters:
gtuType
- GtuType; GTU typespeedLimit
- Speed; speed limitmaxGtuSpeed
- Speed; maximum GTU speedparameters
- Parameters; parameters for the next GTU- Returns:
- desired speed of the next GTU to be generated at the given location, may be
null
at which point the GTU generator will use some other speed - Throws:
GtuException
- on any exception
-
peekDesiredHeadway
default org.djunits.value.vdouble.scalar.Length peekDesiredHeadway(GtuType gtuType, org.djunits.value.vdouble.scalar.Speed speed, org.opentrafficsim.base.parameters.Parameters parameters) throws GtuException Peek to see the desired headway of the next GTU to be generated at the given speed. The default implementation returnsnull
, at which point the GTU generator will only generate GTU's at fixed locations.- Parameters:
gtuType
- GtuType; GTU typespeed
- Speed; speed the GTU might be generated atparameters
- Parameters; parameters for the next GTU- Returns:
- Length; desired headway of the next GTU to be generated at the given speed, may be
null
at which point the GTU generator will only generate GTU's at fixed locations - Throws:
GtuException
- on any exception
-