Interface TimestampTallyInterface

All Superinterfaces:
BasicTallyInterface, Serializable, WeightedTallyInterface
All Known Implementing Classes:
EventBasedTimestampWeightedTally, TimestampWeightedTally

public interface TimestampTallyInterface
extends WeightedTallyInterface
The TimestampedTally interface defines the methods that a timestamped tally should implement in addition to the standard weighted tally. Timestamps can, e.g., be Number based or Calendar based.

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

Author:
Alexander Verbraeck, Peter Knoppers
  • Method Details

    • isActive

      boolean isActive()
      Return whether the statistic is active (accepting observations) or not.
      Returns:
      boolean; whether the statistic is active (accepting observations) or not
    • endObservations

      void endObservations​(Number timestamp)
      End the observations and closes the last interval of observations. After ending, no more observations will be accepted. Calling this method will create an extra observation, and corresponding events for the EventBased implementations of this interface will be called.
      Parameters:
      timestamp - Number; the Number object representing the final timestamp
    • endObservations

      void endObservations​(Calendar timestamp)
      End the observations and closes the last interval of observations. After ending, no more observations will be accepted. Calling this method will create an extra observation, and corresponding events for the EventBased implementations of this interface will be called.
      Parameters:
      timestamp - Calendar; the Calendar object representing the final timestamp