简体   繁体   中英

How to read lucene 4.0 index with java?

I've used Lucene 4.0 and I can not find the "term()" method in IndexReader class with Lucene version 4.0. How to read the index? Please help. I want to know the contents (Terms, Term Frequency and so on) of the index file.Thanks.

My bet is that you need to use http://lucene.apache.org/core/4_0_0/core/org/apache/lucene/index/AtomicReader.html , it have all needed methods.

Also take a look here - http://lucene.apache.org/core/4_0_0/core/org/apache/lucene/index/IndexReader.html - it explain you how to create needed readers.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM