Interface PerceivedGtu

All Superinterfaces:
Comparable<PerceivedObject>, Identifiable, PerceivedObject
All Known Implementing Classes:
PerceivedGtuBase, PerceivedGtuSimple

public interface PerceivedGtu extends PerceivedObject
Interface for perceived surrounding GTU's, adding signals, maneuver and behavioral information.

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 Details

    • getGtuType

      GtuType getGtuType()
      Returns the GTU type.
      Returns:
      gtuType
    • getWidth

      Length getWidth()
      Returns the width of the GTU.
      Returns:
      width of the GTU
    • getSignals

      PerceivedGtu.Signals getSignals()
      Returns information on the signals. This includes indicators and braking lights.
      Returns:
      information on the signals
    • getManeuver

      PerceivedGtu.Maneuver getManeuver()
      Returns information on the maneuver. This includes lane changing and lateral deviation.
      Returns:
      information on the maneuver
    • getBehavior

      PerceivedGtu.Behavior getBehavior()
      Returns information on the behavior. This includes the car-following model, parameters, desired speed, route, lane change desire and social pressure.
      Returns:
      information on the behavior
    • moved

      default PerceivedGtu moved(Length headway, Speed speed, Acceleration acceleration)
      Returns a view of this perceived headway GTU that returns different values for the headway, speed and acceleration.
      Parameters:
      headway - headway
      speed - speed
      acceleration - acceleration
      Returns:
      copy with different headway, speed and acceleration
      Throws:
      NullPointerException - when any input argument is null
      IllegalStateException - when this perceived GTU is parallel
    • of

      Returns perceived GTU with given kinematics.
      Parameters:
      gtu - GTU that is perceived
      kinematics - kinematics for the vehicle
      Returns:
      perceived view of the GTU
      Throws:
      NullPointerException - when gtu is null
    • of

      static PerceivedGtu of(LaneBasedGtu gtu, PerceivedObject.Kinematics kinematics, Duration time)
      Returns perceived GTU at the given time with given kinematics.
      Parameters:
      gtu - GTU that is perceived
      kinematics - kinematics for the vehicle
      time - simulation time at which the GTU is perceived
      Returns:
      perceived view of the GTU
      Throws:
      NullPointerException - when gtu is null