public void generate(IndexReader reader) throws IOException {
TermEnum enumerator = new WildcardTermEnum(reader, wildcard);
TermDocs termDocs = reader.termDocs();
try {
do {
Term term = enumerator.term();
if (term==null) break;
termDocs.seek(term);
while (termDocs.next()) {
handleDoc(termDocs.doc());
}