public class Distraction extends AbstractLaneBasedObject
 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.
 
| Modifier and Type | Class and Description | 
|---|---|
static interface  | 
Distraction.DistractionProfile
Describes the profile around the distraction. 
 | 
static class  | 
Distraction.TrapezoidProfile
Distraction profile with trapezoid shape. 
 | 
listenersFIRST_POSITION, LAST_POSITION| Constructor and Description | 
|---|
Distraction(String id,
           Lane lane,
           Length longitudinalPosition,
           SimulatorInterface.TimeDoubleUnit simulator,
           Distraction.DistractionProfile profile)  | 
| Modifier and Type | Method and Description | 
|---|---|
AbstractLaneBasedObject | 
clone(CrossSectionElement newCSE,
     SimulatorInterface.TimeDoubleUnit newSimulator)
Clone the LaneBasedObject for e.g., copying a network. 
 | 
Double | 
getDistraction(Length distance)
Returns the level of distraction at the given distance. 
 | 
clone, getDirection, getFullId, getLane, getLocation, getLongitudinalPosition, toStringgetBounds, getGeometry, getHeight, getIdaddListener, addListener, addListener, addListener, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, removeAllListeners, removeAllListeners, removeListenerclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetBounds, makeGeometrygetGeometry, getHeightgetIdaddListener, addListener, addListener, addListener, removeListenerpublic Distraction(String id, Lane lane, Length longitudinalPosition, SimulatorInterface.TimeDoubleUnit simulator, Distraction.DistractionProfile profile) throws NetworkException
id - String; idlane - Lane; lanelongitudinalPosition - Length; longitudinal positionsimulator - SimulatorInterface.TimeDoubleUnit; simulatorprofile - DistractionProfile; distraction profileNetworkException - on network exceptionpublic AbstractLaneBasedObject clone(CrossSectionElement newCSE, SimulatorInterface.TimeDoubleUnit newSimulator) throws NetworkException
clone in class AbstractLaneBasedObjectnewCSE - CrossSectionElement; the new cross section element to which the clone belongsnewSimulator - SimulatorInterface.TimeDoubleUnit; the new simulator for this networkNetworkException - in case the cloning failsCopyright © 2014–2019 Delft University of Technology. All rights reserved.