class RecordedValuesIterator extends AbstractHistogramIterator implements Iterator<HistogramIterationValue> {
    int visitedIndex;

    /**
     * Reset iterator for re-use in a fresh iteration over the same histogram data set.
     */
    public void reset() {
        reset(histogram);
    }

    private void reset(final AbstractHistogram histogram) {
        super.resetIterator(histogram);
        visitedIndex = -1;
    }

    /**
     * @param histogram The histogram this iterator will operate on
     */
    public RecordedValuesIterator(final AbstractHistogram histogram) {
        reset(histogram);
    }

    @Override
    void incrementIterationLevel() {
        visitedIndex = currentIndex;
    }

    @Override
    boolean reachedIterationLevel() {<FILL_FUNCTION_BODY>}
}

        long currentCount = histogram.getCountAtIndex(currentIndex);
        return (currentCount != 0) && (visitedIndex != currentIndex);
    
<methods>public boolean hasNext() ,public org.HdrHistogram.HistogramIterationValue next() ,public void remove() <variables>long arrayTotalCount,long countAtThisValue,int currentIndex,final org.HdrHistogram.HistogramIterationValue currentIterationValue,long currentValueAtIndex,private boolean freshSubBucket,org.HdrHistogram.AbstractHistogram histogram,private double integerToDoubleValueConversionRatio,long nextValueAtIndex,long prevValueIteratedTo,long totalCountToCurrentIndex,long totalCountToPrevIndex,long totalValueToCurrentIndex