public synchronized < T > T harvest ( Function < Histogram , T > consumer ) { initializeRecorder ( ) ; _recycle = _recorder . getIntervalHistogram ( _recycle ) ; return consumer . apply ( _recycle ) ; }
Allows consuming histogram and returning a result . Histogram passed to the consumer includes stable consistent view of all values accumulated since last harvest . This method is thread safe .