java.lang.Object
org.apache.jackrabbit.oak.index.indexer.document.flatfile.pipelined.BoundedHistogram

public class BoundedHistogram extends Object
A histogram that keeps a maximum number of buckets (entries). When the histogram is at the limit, it will reject new entries but keep updating the count of the existing entries. Therefore, the counts for the entries in the histogram are correct but if the histogram overflowed, it may be missing some entries.
  • Constructor Details

    • BoundedHistogram

      public BoundedHistogram(String name, int maxHistogramSize)
  • Method Details

    • addEntry

      public void addEntry(String key)
    • isOverflowed

      public boolean isOverflowed()
    • getMap

    • prettyPrint

      public String prettyPrint()
    • prettyPrintTopEntries

      public String prettyPrintTopEntries(int numEntries)