public final class Lucene90BlockTreeTermsReader extends FieldsProducerA block-based terms index and dictionary that assigns terms to variable length blocks according to how they share prefixes. The terms index is a prefix trie whose leaves are term blocks. The advantage of this approach is that seekExact is often able to determine a term cannot exist without doing any IO, and intersection with Automata is very fast. Note that this terms dictionary has its own fixed terms index (ie, it does not support a pluggable terms index implementation).
NOTE: this terms dictionary supports min/maxItemsPerBlock during indexing to control how much memory the terms index uses.
The data structure used by this implementation is very similar to a burst trie (http://citeseer.ist.psu.edu/viewdoc/summary?doi=10.1.1.18.3499), but with added logic to break up too-large blocks of all terms sharing a given prefix into smaller ones.
-verboseoption to see summary statistics on the blocks in the dictionary.
- WARNING: This API is experimental and might change in incompatible ways in the next release.
All Methods Instance Methods Concrete Methods Modifier and Type Method Description
checkIntegrity()Checks consistency of this reader.
iterator()Returns an iterator that will step through all fields names.
size()Returns the number of fields or -1 if the number of distinct field names is unknown.
terms(String field)Get the
Termsfor this field.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
public void close() throws IOException
iteratorReturns an iterator that will step through all fields names. This will not return null.
public Terms terms(String field) throws IOExceptionGet the
Termsfor this field. This will return null if the field does not exist.
public int size()Returns the number of fields or -1 if the number of distinct field names is unknown. If >= 0,
Fields.iterator()will return as many field names.
public void checkIntegrity() throws IOExceptionDescription copied from class:
FieldsProducerChecks consistency of this reader.
Note that this may be costly in terms of I/O, e.g. may involve computing a checksum value against large data files.