Interface PlotScheduler


public interface PlotScheduler
Interface between plots (subclasses of AbstractPlot) and some source that knows about time in the context, e.g. a simulator, or a data loader which knows all time has past. For offline purposes, PlotScheduler.OFFLINE can be used.

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

Author:
Wouter Schakel
  • Field Details

    • OFFLINE

      static final PlotScheduler OFFLINE
      Default offline scheduler. This will only provide an infinite time, causing AbstractPlot.update() to be invoked on all plots once.
  • Method Details

    • getTime

      org.djunits.value.vdouble.scalar.Duration getTime()
      Returns the time.
      Returns:
      time
    • cancelEvent

      default void cancelEvent(AbstractPlot<?> abstractPlot)
      Cancel event on plot.

      The default implementation does nothing, allowing non-verbose anonymous extensions.

      Parameters:
      abstractPlot - plot
    • scheduleUpdate

      default void scheduleUpdate(org.djunits.value.vdouble.scalar.Duration time, AbstractPlot<?> abstractPlot)
      Schedule AbstractPlot.update() call on abstractPlot.

      The default implementation does nothing, allowing non-verbose anonymous extensions.

      Parameters:
      time - time.
      abstractPlot - plot.
    • scheduleUpdateNow

      default void scheduleUpdateNow(AbstractPlot<?> abstractPlot)
      Schedule AbstractPlot.update() call on abstractPlot now.

      The default implementation does nothing, allowing non-verbose anonymous extensions.

      Parameters:
      abstractPlot - plot.