Increments the iteration to the next BytesRef in the iterator. Returns the resulting
BytesRef or null if the end of the iterator is reached. The returned
BytesRef may be re-used across calls to next. After this method returns null, do not call it
again: the results are undefined.
Returns: the next BytesRef in the iterator or null if the end of the
iterator is reached.
An empty TermsEnum for quickly returning an empty instance e.g. in org.apache.lucene.search.MultiTermQuery
Please note: This enum should be unmodifiable, but it is currently possible to add
Attributes to it. This should not be a problem, as the enum is always empty and the existence
of unused Attributes does not matter.
doc_freq
int doc_freq()
Java: docFreq()
Returns the number of documents containing the current term. Do not call this when the enum is
unpositioned. SeekStatus#END.
Returns ordinal position for current term. This is an optional method (the codec may throw
UnsupportedOperationException). Do not call this when the enum is unpositioned.
Get PostingsEnum for the current term. Do not call this when the enum is unpositioned.
This method will not return null.
NOTE: the returned iterator may return deleted documents, so deleted documents have
to be checked on top of the PostingsEnum.
Use this method if you only require documents and frequencies, and do not need any proximity
data. This method is equivalent to postings(reuse,
PostingsEnum.FREQS)
Java: postings(org.apache.lucene.index.PostingsEnum reuse, int flags)
Get PostingsEnum for the current term, with control over whether freqs, positions,
offsets or payloads are required. Do not call this when the enum is unpositioned. This method
will not return null.
NOTE: the returned iterator may return deleted documents, so deleted documents have
to be checked on top of the PostingsEnum.
name
type
description
reuse
org.apache.lucene.index.PostingsEnum
pass a prior PostingsEnum for possible reuse
flags
int
specifies which optional per-document values you require; see PostingsEnum#FREQS
Seeks to the specified term, if it exists, or to the next (ceiling) term. Returns SeekStatus to
indicate whether exact term was found, a different term was found, or EOF was hit. The target
term may be before or after the current term. If this returns SeekStatus.END, the enum is
unpositioned.
seek_exact
seek_exact(long ord)
Java: seekExact(long ord)
Seeks to the specified term by ordinal (position) as previously returned by #ord. The
target ord may be before or after the current ord, and must be within bounds.
Returns current term. Do not call this when the enum is unpositioned.
total_term_freq
long total_term_freq()
Java: totalTermFreq()
Returns the total number of occurrences of this term across all documents (the sum of the
freq() for each doc that has this term). Note that, like other term measures, this measure does
not take deleted documents into account.