Class CircularRoadSwing

    • Constructor Detail

      • CircularRoadSwing

        public CircularRoadSwing​(String title,
                                 OTSAnimationPanel panel,
                                 CircularRoadModel model)
                          throws org.opentrafficsim.draw.core.OTSDrawingException
        Create a CircularRoad Swing application.
        Parameters:
        title - String; the title of the Frame
        panel - OTSAnimationPanel; the tabbed panel to display
        model - CircularRoadModel; the model
        Throws:
        org.opentrafficsim.draw.core.OTSDrawingException - on animation error
    • Method Detail

      • main

        public static void main​(String[] args)
        Main program.
        Parameters:
        args - String[]; the command line arguments (not used)
      • simulatorDemo

        public static void simulatorDemo()
        Run the simulation without animation.
      • clickStart

        public static boolean clickStart​(Component component)
        Find the start simulation button and click it.
        Parameters:
        component - Component; some component that could be the start button, or a container that contains the start button
        Returns:
        boolean; true if the start button was found (and clicked); false otherwise
      • clickRunPause

        public static boolean clickRunPause​(Component component)
        Click the button that starts the animated simulation.
        Parameters:
        component - Component; some component that (hopefully) is, or contains the start button
        Returns:
        boolean; true if the button was found (and clicked); false if the start button was not found
      • demo

        public static void demo​(boolean exitOnClose)
        Start the demo.
        Parameters:
        exitOnClose - boolean; when running stand-alone: true; when running as part of a demo: false
      • addStatisticsTabs

        protected final void addStatisticsTabs​(org.opentrafficsim.core.dsol.OTSSimulatorInterface simulator)
        Add the statistics tabs.
        Parameters:
        simulator - OTSSimulatorInterface; the simulator on which sampling can be scheduled