Package org.HdrHistogram
Class DoublePercentileIterator
- java.lang.Object
-
- org.HdrHistogram.DoublePercentileIterator
-
- All Implemented Interfaces:
java.util.Iterator<DoubleHistogramIterationValue>
public class DoublePercentileIterator extends java.lang.Object implements java.util.Iterator<DoubleHistogramIterationValue>
Used for iterating throughDoubleHistogram
values values according to percentile levels. The iteration is performed in steps that start at 0% and reduce their distance to 100% according to the percentileTicksPerHalfDistance parameter, ultimately reaching 100% when all recorded histogram values are exhausted.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) DoubleHistogram
histogram
private PercentileIterator
integerPercentileIterator
private DoubleHistogramIterationValue
iterationValue
-
Constructor Summary
Constructors Constructor Description DoublePercentileIterator(DoubleHistogram histogram, int percentileTicksPerHalfDistance)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
hasNext()
DoubleHistogramIterationValue
next()
void
remove()
void
reset(int percentileTicksPerHalfDistance)
Reset iterator for re-use in a fresh iteration over the same histogram data set.
-
-
-
Field Detail
-
integerPercentileIterator
private final PercentileIterator integerPercentileIterator
-
iterationValue
private final DoubleHistogramIterationValue iterationValue
-
histogram
DoubleHistogram histogram
-
-
Constructor Detail
-
DoublePercentileIterator
public DoublePercentileIterator(DoubleHistogram histogram, int percentileTicksPerHalfDistance)
- Parameters:
histogram
- The histogram this iterator will operate onpercentileTicksPerHalfDistance
- The number of iteration steps per half-distance to 100%.
-
-
Method Detail
-
reset
public void reset(int percentileTicksPerHalfDistance)
Reset iterator for re-use in a fresh iteration over the same histogram data set.- Parameters:
percentileTicksPerHalfDistance
- The number of iteration steps per half-distance to 100%.
-
hasNext
public boolean hasNext()
- Specified by:
hasNext
in interfacejava.util.Iterator<DoubleHistogramIterationValue>
-
next
public DoubleHistogramIterationValue next()
- Specified by:
next
in interfacejava.util.Iterator<DoubleHistogramIterationValue>
-
remove
public void remove()
- Specified by:
remove
in interfacejava.util.Iterator<DoubleHistogramIterationValue>
-
-