Interface EgoPerception<G extends Gtu,P extends Perception<G>>
-
- Type Parameters:
G- GTU typeP- perception type
- All Superinterfaces:
PerceptionCategory<G,P>
- All Known Implementing Classes:
DirectEgoPerception
public interface EgoPerception<G extends Gtu,P extends Perception<G>> extends PerceptionCategory<G,P>
Ego perception interface.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 13 feb. 2017
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description AccelerationgetAcceleration()Returns the acceleration.LengthgetLength()Returns the length.SpeedgetSpeed()Returns the speed.LengthgetWidth()Returns the width.voidupdateAcceleration()Update acceleration.default voidupdateAll()Update all information in the perception category.voidupdateLength()Update length.voidupdateSpeed()Update speed.voidupdateWidth()Update width.
-
-
-
Method Detail
-
updateSpeed
void updateSpeed() throws GtuExceptionUpdate speed.- Throws:
GtuException- if the GTU has not been initialized
-
updateAcceleration
void updateAcceleration() throws GtuExceptionUpdate acceleration.- Throws:
GtuException- if the GTU has not been initialized
-
updateLength
void updateLength() throws GtuExceptionUpdate length.- Throws:
GtuException- if the GTU has not been initialized
-
updateWidth
void updateWidth() throws GtuExceptionUpdate width.- Throws:
GtuException- if the GTU has not been initialized
-
getAcceleration
Acceleration getAcceleration()
Returns the acceleration.- Returns:
- acceleration
-
getSpeed
Speed getSpeed()
Returns the speed.- Returns:
- speed
-
getLength
Length getLength()
Returns the length.- Returns:
- length
-
getWidth
Length getWidth()
Returns the width.- Returns:
- width
-
updateAll
default void updateAll() throws GtuException, NetworkException, ParameterExceptionUpdate all information in the perception category.- Specified by:
updateAllin interfacePerceptionCategory<G extends Gtu,P extends Perception<G>>- Throws:
GtuException- if the GTU was not initializedNetworkException- when lanes are not properly linkedParameterException- when a necessary parameter to carry our perception is not defined (e.g., LOOKAHEAD)
-
-