Class RunUntilPanel.TimeFloatUnit

java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
nl.tudelft.simulation.dsol.swing.gui.control.RunUntilPanel<org.djunits.value.vfloat.scalar.FloatDuration>
nl.tudelft.simulation.dsol.swing.gui.control.RunUntilPanel.TimeFloatUnit
All Implemented Interfaces:
ActionListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, AppearanceControl
Enclosing class:
RunUntilPanel<T extends Number & Comparable<T>>

public static class RunUntilPanel.TimeFloatUnit extends RunUntilPanel<org.djunits.value.vfloat.scalar.FloatDuration>
RunUntilPanel for a float djunits Time. The time formatter and time display can be adjusted.

Copyright (c) 2020-2024 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information DSOL Manual. The DSOL project is distributed under a three-clause BSD-style license, which can be found at DSOL License.

Author:
Alexander Verbraeck
See Also:
  • Constructor Details

    • TimeFloatUnit

      public TimeFloatUnit(SimulatorInterface<org.djunits.value.vfloat.scalar.FloatDuration> simulator)
      Construct a clock panel with a djunits FloatDuration.
      Parameters:
      simulator - SimulatorInterface<T>; the simulator
  • Method Details

    • formatSimulationTime

      protected String formatSimulationTime(org.djunits.value.vfloat.scalar.FloatDuration simulationTime)
      Returns the formatted simulation time.
      Specified by:
      formatSimulationTime in class RunUntilPanel<org.djunits.value.vfloat.scalar.FloatDuration>
      Parameters:
      simulationTime - T; simulation time
      Returns:
      formatted simulation time
    • parseSimulationTime

      protected org.djunits.value.vfloat.scalar.FloatDuration parseSimulationTime(String simulationTimeString)
      Returns the simulation time from the formatted string.
      Specified by:
      parseSimulationTime in class RunUntilPanel<org.djunits.value.vfloat.scalar.FloatDuration>
      Parameters:
      simulationTimeString - String; simulation time as a string
      Returns:
      T; simulation time contained in the String or null when not valid