org.apache.lucene.search.grouping

Class FirstPassGroupingCollector<T>

    • Constructor Detail

      • FirstPassGroupingCollector

        public FirstPassGroupingCollector(Sort groupSort,
                                          int topNGroups)
                                   throws IOException
        Create the first pass collector.
        Parameters:
        groupSort - The Sort used to sort the groups. The top sorted document within each group according to groupSort, determines how that group sorts against other groups. This must be non-null, ie, if you want to groupSort by relevance use Sort.RELEVANCE.
        topNGroups - How many top groups to keep.
        Throws:
        IOException - If I/O related errors occur