Interface PerceivedObject.Kinematics.Overlap

All Known Implementing Classes:
PerceivedObject.Kinematics.Overlap.Record
Enclosing interface:
PerceivedObject.Kinematics

public static interface PerceivedObject.Kinematics.Overlap
Description of overlap information. If the object is fully ahead or behind, overlap values are null.
  • Field Details

  • Method Details

    • getOverlap

      Optional<Length> getOverlap()
      Return the (perceived) overlap with the other object. This value should be null if there is no overlap. In the figure below for two GTUs, it is distance b, positive for GTU1 and GTU2.
       ----------
       |  GTU 1 |          ----->
       ----------
            ---------------
            |    GTU 2    |          ----->
            ---------------
       | a  | b |     c   |
       
      Returns:
      the (perceived) overlap with the other object or empty if there is no overlap
    • getOverlapFront

      Optional<Length> getOverlapFront()
      Return the (perceived) front overlap to the other object. This value should be null if there is no overlap. In the figure for two GTUs below, it is distance c, positive for GTU1, negative for GTU2.
       ----------
       |  GTU 1 |          ----->
       ----------
            ---------------
            |    GTU 2    |          ----->
            ---------------
       | a  | b |     c   |
       
      Returns:
      the (perceived) front overlap to the other object or empty if there is no overlap
    • getOverlapRear

      Optional<Length> getOverlapRear()
      Return the (perceived) rear overlap to the other object. This value should be null if there is no overlap.In the figure below for two GTUs, it is distance a, positive for GTU1, negative for GTU2.
       ----------
       |  GTU 1 |          ----->
       ----------
            ---------------
            |    GTU 2    |          ----->
            ---------------
       | a  | b |     c   |
       
      Returns:
      the (perceived) rear overlap to the other object or empty if there is no overlap
    • isAhead

      boolean isAhead()
      Returns whether the object is fully ahead.
      Returns:
      whether the other object is in front of the reference object
    • isBehind

      boolean isBehind()
      Returns whether the object is fully behind.
      Returns:
      whether the other object is behind the reference object
    • isParallel

      default boolean isParallel()
      Returns whether the object is parallel, partially or fully.
      Returns:
      whether the other object is parallel the reference object