Class UniformTimeValuesSnapshot

java.lang.Object
org.glassfish.jersey.server.internal.monitoring.core.AbstractTimeSnapshot
org.glassfish.jersey.server.internal.monitoring.core.UniformTimeValuesSnapshot
All Implemented Interfaces:
UniformTimeSnapshot

public class UniformTimeValuesSnapshot extends AbstractTimeSnapshot
A statistical snapshot of a UniformTimeValuesSnapshot.
Author:
Stepan Vavra, Dropwizard Team
See Also:
  • Constructor Details

    • UniformTimeValuesSnapshot

      public UniformTimeValuesSnapshot(Collection<Long> values, long timeInterval, TimeUnit timeIntervalUnit)
      Create a new snapshot with the given values.
      Parameters:
      values - an unordered set of values in the reservoir
      timeInterval - The time interval this snapshot relates to
      timeIntervalUnit - The time unit of the time interval
  • Method Details

    • getValue

      public double getValue(double quantile)
      Returns the value at the given quantile.
      Parameters:
      quantile - a given quantile, in [0..1]
      Returns:
      the value in the distribution at quantile
    • size

      public long size()
      Returns the number of values in the snapshot.
      Returns:
      the number of values
    • getValues

      public long[] getValues()
      Returns the entire set of values in the snapshot.
      Returns:
      the entire set of values
    • getMax

      public long getMax()
      Returns the highest value in the snapshot.
      Returns:
      the highest value
    • getMin

      public long getMin()
      Returns the lowest value in the snapshot.
      Returns:
      the lowest value
    • getMean

      public double getMean()
      Returns the arithmetic mean of the values in the snapshot.
      Returns:
      the arithmetic mean