Class ClockPanel.TimeDoubleUnit

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

public static class ClockPanel.TimeDoubleUnit extends ClockPanel<org.djunits.value.vdouble.scalar.Duration>
ClockLabel for a djunits Time. The formatter 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

    • TimeDoubleUnit

      public TimeDoubleUnit(SimulatorInterface<org.djunits.value.vdouble.scalar.Duration> simulator)
      Construct a clock panel with a double time with a unit.
      Parameters:
      simulator - SimulatorInterface<T>; the simulator
  • Method Details

    • formatSimulationTime

      protected String formatSimulationTime(org.djunits.value.vdouble.scalar.Duration simulationTime)
      Returns the formatted simulation time.
      Specified by:
      formatSimulationTime in class ClockPanel<org.djunits.value.vdouble.scalar.Duration>
      Parameters:
      simulationTime - T; simulation time
      Returns:
      formatted simulation time