Class AbstractTrafficLightController

  • All Implemented Interfaces:
    org.opentrafficsim.base.Identifiable, TrafficLightController

    public abstract class AbstractTrafficLightController
    extends Object
    implements TrafficLightController
    Standard fields and methods for traffic light controllers.

    Copyright (c) 2013-2022 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
    BSD-style license. See OpenTrafficSim License.

    $LastChangedDate: 2015-07-24 02:58:59 +0200 (Fri, 24 Jul 2015) $, @version $Revision: 1147 $, by $Author: averbraeck $, initial version Oct 4, 2016
    Author:
    Alexander Verbraeck, Peter Knoppers, Wouter Schakel
    • Field Detail

      • currentPhase

        protected int currentPhase
        the current phase.
      • currentColor

        protected TrafficLightColor currentColor
        the current light in the current phase.
    • Constructor Detail

      • AbstractTrafficLightController

        public AbstractTrafficLightController​(String id,
                                              OTSSimulatorInterface simulator)
        Create a fixed time controller.
        Parameters:
        id - String; the controller id
        simulator - OTSSimulatorInterface; the simulator