Class EnhancementsPayloadIterator

    • Constructor Detail

      • EnhancementsPayloadIterator

        public EnhancementsPayloadIterator​(List<CategoryEnhancement> enhancementsList,
                                           org.apache.lucene.index.IndexReader indexReader,
                                           org.apache.lucene.index.Term term)
                                    throws IOException
        Constructor.
        Parameters:
        enhancementsList - A list of the CategoryEnhancements from the indexing params.
        indexReader - A reader of the index.
        term - The category term to iterate.
        Throws:
        IOException
    • Method Detail

      • setdoc

        public boolean setdoc​(int docId)
                       throws IOException
        Description copied from class: PayloadIterator
        Skip forward to document docId. Return true if this document exists and has any payload.

        Users should call this method with increasing docIds, and implementations can assume that this is the case.

        Overrides:
        setdoc in class PayloadIterator
        Throws:
        IOException
      • getCategoryData

        public Object getCategoryData​(CategoryEnhancement enhancedCategory)
        Get the data of the current category and document for a certain enhancement, or null if no such enhancement exists.
        Parameters:
        enhancedCategory - The category enhancement to apply.
        Returns:
        the data of the current category and document for a certain enhancement, or null if no such enhancement exists.