Class Filter<T extends Summary>

  • Type Parameters:
    T - Summary type against which apply the Predicate

    public class Filter<T extends Summary>
    extends Object
    Class for filtering entries from a Sketch given a Summary
    • Constructor Detail

      • Filter

        public Filter​(Predicate<T> predicate)
        Filter constructor with a Predicate
        Parameters:
        predicate - Predicate to use in this filter. If the Predicate returns False, the element is discarded. If the Predicate returns True, then the element is kept in the Sketch
    • Method Detail

      • filter

        public CompactSketch<T> filter​(Sketch<T> sketchIn)
        Filters elements on the provided Sketch
        Parameters:
        sketchIn - The sketch against which apply the Predicate
        Returns:
        A new Sketch with some of the entries filtered out based on the Predicate