Interface Task
-
- All Superinterfaces:
Identifiable
- All Known Implementing Classes:
AbstractTask
,ConstantTask
,ExponentialTask
,TaskCarFollowing
,TaskHeadwayBased
,TaskLaneChanging
,TaskRoadSideDistraction
public interface Task extends Identifiable
Interface for tasks, where each describes a fundamental relation between exogenous inputs causing a mental task demand. The concept of anticipation reliance can be included, which is a reduction of mental task demand by prioritizing a primary task and relying more on anticipation regarding secondary tasks. Control over the amount of anticipation reliance is implementation dependent, but is typically not part of the task itself.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 3 apr. 2018
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description double
calculateTaskDemand(LanePerception perception, LaneBasedGTU gtu, Parameters parameters)
Returns the gross task demand to be managed by a task manager.double
getAnticipationReliance()
Returns the level of anticipation reliance.double
getTaskDemand()
Returns the gross demand of this task, i.e without considering anticipation reliance.void
setAnticipationReliance(double anticipationReliance)
Set anticipation reliance.void
setTaskDemand(double taskDemand)
Sets (gross) task demand.-
Methods inherited from interface org.opentrafficsim.base.Identifiable
getId
-
-
-
-
Method Detail
-
calculateTaskDemand
double calculateTaskDemand(LanePerception perception, LaneBasedGTU gtu, Parameters parameters) throws ParameterException, GTUException
Returns the gross task demand to be managed by a task manager.- Parameters:
perception
- LanePerception; perceptiongtu
- LaneBasedGTU; gtuparameters
- Parameters; parameters- Returns:
- double; gross task demand
- Throws:
ParameterException
- if a parameter is missing or out of boundsGTUException
- exceptions pertaining to the GTU
-
setTaskDemand
void setTaskDemand(double taskDemand)
Sets (gross) task demand.- Parameters:
taskDemand
- double; set task demand
-
getTaskDemand
double getTaskDemand()
Returns the gross demand of this task, i.e without considering anticipation reliance.- Returns:
- double; gross demand of this task, i.e. without considering anticipation reliance
-
setAnticipationReliance
void setAnticipationReliance(double anticipationReliance)
Set anticipation reliance.- Parameters:
anticipationReliance
- double; set anticipation reliance
-
getAnticipationReliance
double getAnticipationReliance()
Returns the level of anticipation reliance.- Returns:
- double; anticipation reliance
-
-