java.lang.Object
net.i2p.stat.RateSampleDelivery.Sample
Enclosing class:
RateSampleDelivery

private static final class RateSampleDelivery.Sampleextends Object
One coalesced sample, detached from the Rate that produced it.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    (package private) final long
    The number of events in the sample.
    (package private) final RateSummaryListener
    The listener to notify with the sample.
    (package private) final long
    The period the sample covers, in ms.
    (package private) final long
    timestampMs / period: the archive step this sample is for.
    (package private) final long
    The sample's archive step stamp, carried from Rate.coalesce().
    (package private) final double
    The total event time in the sample.
    (package private) final double
    The total value the sample sums up.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Sample(RateSummaryListener listener, double totalValue, long eventCount, double totalEventTime, long period, long timestampMs)
    Builds one sample to deliver.
  • Method Summary

    Methods inherited from class Object

    clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • listener

      final RateSummaryListener listener
      The listener to notify with the sample.
    • totalValue

      final double totalValue
      The total value the sample sums up.
    • eventCount

      final long eventCount
      The number of events in the sample.
    • totalEventTime

      final double totalEventTime
      The total event time in the sample.
    • period

      final long period
      The period the sample covers, in ms.
    • timestampMs

      final long timestampMs
      The sample's archive step stamp, carried from Rate.coalesce().
    • step

      final long step
      timestampMs / period: the archive step this sample is for.
  • Constructor Details

    • Sample

      Sample(RateSummaryListener listener, double totalValue, long eventCount, double totalEventTime, long period, long timestampMs)
      Builds one sample to deliver.
      Parameters:
      listener - the listener to notify
      totalValue - the total value summed
      eventCount - the number of events
      totalEventTime - the total event time
      period - the period covered, in ms
      timestampMs - when the sample was taken