List of usage examples for org.apache.lucene.util BitSetIterator nextDoc
@Override
public int nextDoc()
From source file:org.elasticsearch.percolator.PercolatorMatchedSlotSubFetchPhase.java
License:Apache License
static int[] buildRootDocsSlots(BitSet rootDocs) { int slot = 0; int[] rootDocsBySlot = new int[rootDocs.cardinality()]; BitSetIterator iterator = new BitSetIterator(rootDocs, 0); for (int rootDocId = iterator.nextDoc(); rootDocId != NO_MORE_DOCS; rootDocId = iterator.nextDoc()) { rootDocsBySlot[slot++] = rootDocId; }/*from w ww . j a v a2 s . co m*/ return rootDocsBySlot; }