Class ClassicHistogramBuckets
Object
ClassicHistogramBuckets
- All Implemented Interfaces:
Iterable<ClassicHistogramBucket>
Immutable container for histogram buckets with fixed bucket boundaries. Note that the counts are
not cumulative.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ClassicHistogramBucketsUsed in native histograms to indicate that no classic histogram buckets are present. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()To create newClassicHistogramBuckets, you can either use one of the staticof(...)methods, or usebuilder().longgetCount(int i) The count is not cumulative.doublegetUpperBound(int i) booleanisEmpty()iterator()static ClassicHistogramBucketsof(double[] upperBounds, long[] counts) To create newClassicHistogramBuckets, you can either use one of the staticof(...)methods, or usebuilder().static ClassicHistogramBucketsTo create newClassicHistogramBuckets, you can either use one of the staticof(...)methods, or usebuilder().static ClassicHistogramBucketsTo create newClassicHistogramBuckets, you can either use one of the staticof(...)methods, or usebuilder().intsize()stream()Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Iterable
forEach, spliterator
-
Field Details
-
EMPTY
Used in native histograms to indicate that no classic histogram buckets are present.
-
-
Method Details
-
of
To create newClassicHistogramBuckets, you can either use one of the staticof(...)methods, or usebuilder().This method will create a copy of upperBounds and counts.
- Parameters:
upperBounds- must have the same length as counts. Must not contain duplicates. Must contain at leastDouble.POSITIVE_INFINITYfor the+Infbucket. An upper bound must not beDouble.NaN. The upperBounds array does not need to be sorted.counts- must have the same length asupperBounds. The entry at indexiis the count for theupperBoundsat indexi. For each count,Number.longValue()is called to get the value. Counts are not cumulative. Counts must not be negative.
-
of
To create newClassicHistogramBuckets, you can either use one of the staticof(...)methods, or usebuilder().This method will create a copy of upperBounds and counts.
- Parameters:
upperBounds- must have the same length as counts. Must not contain duplicates. Must contain at leastDouble.POSITIVE_INFINITYfor the+Infbucket. An upper bound must not beDouble.NaN. The upperBounds array does not need to be sorted.counts- must have the same length asupperBounds. The entry at indexiis the count for theupperBoundsat indexi. For each count,Number.longValue()is called to get the value. Counts are not cumulative. Counts must not be negative.
-
of
To create newClassicHistogramBuckets, you can either use one of the staticof(...)methods, or usebuilder().This method will create a copy of upperBounds and counts.
- Parameters:
upperBounds- must have the same length as counts. Must not contain duplicates. Must contain at leastDouble.POSITIVE_INFINITYfor the+Infbucket. An upper bound must not beDouble.NaN. The upperBounds array does not need to be sorted.counts- must have the same length asupperBounds. The entry at indexiis the count for theupperBoundsat indexi. Counts are not cumulative. Counts must not be negative.
-
size
-
getUpperBound
-
getCount
The count is not cumulative. -
isEmpty
-
iterator
- Specified by:
iteratorin interfaceIterable<ClassicHistogramBucket>
-
stream
-
builder
To create newClassicHistogramBuckets, you can either use one of the staticof(...)methods, or usebuilder().
-