Class LaneTest.MockSensor

  • Enclosing class:
    LaneTest

    class LaneTest.MockSensor
    extends Object
    Mock a SingleSensor.
    • Constructor Detail

      • MockSensor

        MockSensor​(String id,
                   Length position)
        Construct a new Mocked SingleSensor.
        Parameters:
        id - String; result of the getId() method of the mocked SingleSensor
        position - Length; result of the getLongitudinalPosition of the mocked SingleSensor
    • Method Detail

      • getMock

        public SingleSensor getMock()
        Retrieve the mocked sensor.
        Returns:
        SingleSensor; the mocked sensor
      • getLongitudinalPosition

        public Length getLongitudinalPosition()
        Retrieve the position of the mocked sensor.
        Returns:
        Length; the longitudinal position of the mocked sensor