public class EstimatedHistogram
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
EstimatedHistogram.EstimatedHistogramSerializer |
Modifier and Type | Field and Description |
---|---|
static EstimatedHistogram.EstimatedHistogramSerializer |
serializer |
Constructor and Description |
---|
EstimatedHistogram() |
EstimatedHistogram(int bucketCount) |
EstimatedHistogram(long[] offsets,
long[] bucketData) |
Modifier and Type | Method and Description |
---|---|
void |
add(long n)
Increments the count of the bucket closest to n, rounding UP.
|
long |
count() |
boolean |
equals(java.lang.Object o) |
long[] |
getBucketOffsets() |
long[] |
getBuckets(boolean reset) |
int |
hashCode() |
boolean |
isOverflowed() |
void |
log(org.slf4j.Logger log)
log.debug() every record in the histogram
|
long |
max() |
long |
mean() |
long |
min() |
long |
percentile(double percentile) |
public static final EstimatedHistogram.EstimatedHistogramSerializer serializer
public EstimatedHistogram()
public EstimatedHistogram(int bucketCount)
public EstimatedHistogram(long[] offsets, long[] bucketData)
public long[] getBucketOffsets()
public void add(long n)
n
- public long[] getBuckets(boolean reset)
reset
- zero out buckets afterwards if truepublic long min()
public long max()
public long percentile(double percentile)
percentile
- public long mean()
java.lang.IllegalStateException
- if any values were greater than the largest bucket thresholdpublic long count()
public boolean isOverflowed()
public void log(org.slf4j.Logger log)
log
- public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
Copyright © 2014 The Apache Software Foundation