Package io.opencensus.metrics.export
Class Distribution.Bucket
- java.lang.Object
-
- io.opencensus.metrics.export.Distribution.Bucket
-
- Direct Known Subclasses:
AutoValue_Distribution_Bucket
- Enclosing class:
- Distribution
@Immutable public abstract static class Distribution.Bucket extends java.lang.Object
The histogram bucket of the population values.- Since:
- 0.17
-
-
Constructor Summary
Constructors Constructor Description Bucket()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static Distribution.Bucket
create(long count)
Creates aDistribution.Bucket
.static Distribution.Bucket
create(long count, Exemplar exemplar)
Creates aDistribution.Bucket
with anExemplar
.abstract long
getCount()
Returns the number of values in each bucket of the histogram.abstract Exemplar
getExemplar()
-
-
-
Method Detail
-
create
public static Distribution.Bucket create(long count)
Creates aDistribution.Bucket
.- Parameters:
count
- the number of values in each bucket of the histogram.- Returns:
- a
Bucket
. - Since:
- 0.17
-
create
public static Distribution.Bucket create(long count, Exemplar exemplar)
Creates aDistribution.Bucket
with anExemplar
.- Parameters:
count
- the number of values in each bucket of the histogram.exemplar
- theExemplar
of thisBucket
.- Returns:
- a
Bucket
. - Since:
- 0.17
-
getCount
public abstract long getCount()
Returns the number of values in each bucket of the histogram.- Returns:
- the number of values in each bucket of the histogram.
- Since:
- 0.17
-
getExemplar
@Nullable public abstract Exemplar getExemplar()
- Returns:
- the
Exemplar
associated with theBucket
, ornull
if there isn't one. - Since:
- 0.17
-
-