java.lang.Object
org.hibernate.search.backend.lucene.lowlevel.join.impl.ChildDocIds

public class ChildDocIds extends Object
A provider of children docIds for a given parent docId.
  • Constructor Details

    • ChildDocIds

      public ChildDocIds(org.apache.lucene.util.BitSet parentDocs, org.apache.lucene.search.DocIdSetIterator childDocs)
  • Method Details

    • advanceExactParent

      public boolean advanceExactParent(int parentDocId) throws IOException
      Parameters:
      parentDocId - The docID of a parent document. Must be strictly greater than the docId passed to this method the last time it was invoked.
      Returns:
      true if there is at least one child for the given parent.
      Throws:
      IOException - If advancing underlying iterators throws an exception.
    • nextChild

      public int nextChild() throws IOException
      Returns:
      The docId of the next child of the parent doc set by the last call to advanceExactParent(int), or DocIdSetIterator.NO_MORE_DOCS if there isn't any more child for this parent doc.
      Throws:
      IOException - If advancing underlying iterators throws an exception.
    • nextChild

      public int nextChild(int target) throws IOException
      Parameters:
      target - The docID of a document. Must be greater than or equal to the docId of the last retrieved child.
      Returns:
      The docId of the next child of the parent doc set by the last call to advanceExactParent(int), beyond previousIdExcluded, or DocIdSetIterator.NO_MORE_DOCS if there isn't any more child for this parent doc beyond previousIdExcluded.
      Throws:
      IOException - If advancing underlying iterators throws an exception.