- All Superinterfaces:
Wrapper
Snapshot in time of a histogram.
-
Method Summary
Modifier and TypeMethodDescriptionlong
count()
Returns the count of observations in the snapshot.static HistogramSnapshot
empty
(long count, double total, double max) Returns an "empty" snapshot which has summary values but no data points.Returns information about each of the configured buckets for the histogram.double
max()
Returns the maximum value over all observations.double
mean()
Returns the average value overall observations.double
Returns the average value over all observations, interpreting the values as times in nanoseconds and expressing the average in the specifiedTimeUnit
.void
outputSummary
(PrintStream out, double scale) Dumps a summary of the snapshot to the specifiedPrintStream
using the indicated scaling factor for observations.Iterable
<? extends ValueAtPercentile> Returns the values at the configured percentiles for the histogram.double
total()
Returns the total value over all observations in the snapshot.double
Returns the total value over all observations, interpreting the values as times in nanoseconds and expressing the time in the specifiedTimeUnit
.
-
Method Details
-
empty
Returns an "empty" snapshot which has summary values but no data points.- Parameters:
count
- count of observations the snapshot should reporttotal
- total value of observations the snapshot should reportmax
- maximum value the snapshot should report- Returns:
- empty snapshot reporting the values as specified
-
count
long count()Returns the count of observations in the snapshot.- Returns:
- count of observations
-
total
double total()Returns the total value over all observations in the snapshot.- Returns:
- total value over all observations
-
total
Returns the total value over all observations, interpreting the values as times in nanoseconds and expressing the time in the specifiedTimeUnit
.- Parameters:
timeUnit
- time unit in which to express the total value- Returns:
- total value expressed in the selected time unit
-
max
double max()Returns the maximum value over all observations.- Returns:
- maximum value
-
mean
double mean()Returns the average value overall observations.- Returns:
- average value
-
mean
Returns the average value over all observations, interpreting the values as times in nanoseconds and expressing the average in the specifiedTimeUnit
.- Parameters:
timeUnit
- time unitin which to express the average- Returns:
- average value expressed in the selected time unit
-
percentileValues
Iterable<? extends ValueAtPercentile> percentileValues()Returns the values at the configured percentiles for the histogram.- Returns:
- pairs of percentile and the histogram value at that percentile
-
histogramCounts
Returns information about each of the configured buckets for the histogram.- Returns:
- pairs of boundary value and count of observations in that boundary
-
outputSummary
Dumps a summary of the snapshot to the specifiedPrintStream
using the indicated scaling factor for observations.- Parameters:
out
-PrintStream
to which to dump the snapshot summaryscale
- scale factor to apply to observations for output
-