iw.addDocument(d);
}
/** Build the "truth" with ALL the facets enumerating indexes content. */
protected Map<CategoryPath, Integer> facetCountsTruth() throws IOException {
FacetIndexingParams iParams = getFacetIndexingParams(Integer.MAX_VALUE);
String delim = String.valueOf(iParams.getFacetDelimChar());
Map<CategoryPath, Integer> res = new HashMap<CategoryPath, Integer>();
HashSet<Term> handledTerms = new HashSet<Term>();
for (CategoryListParams clp : iParams.getAllCategoryListParams()) {
Term baseTerm = clp.getTerm().createTerm("");
if (!handledTerms.add(baseTerm)) {
continue; // already handled this term (for another list)
}
TermEnum te = indexReader.terms(baseTerm);