|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.lucene.search.DocIdSetIterator
org.apache.lucene.index.DocsEnum
public abstract class DocsEnum
Iterates through the documents and term freqs.
NOTE: you must first call DocIdSetIterator.nextDoc()
before using
any of the per-doc methods.
Field Summary | |
---|---|
static int |
FLAG_FREQS
Flag to pass to TermsEnum.docs(Bits,DocsEnum,int)
if you require term frequencies in the returned enum. |
static int |
FLAG_NONE
Flag to pass to TermsEnum.docs(Bits,DocsEnum,int) if you don't
require term frequencies in the returned enum. |
Fields inherited from class org.apache.lucene.search.DocIdSetIterator |
---|
NO_MORE_DOCS |
Constructor Summary | |
---|---|
protected |
DocsEnum()
Sole constructor. |
Method Summary | |
---|---|
AttributeSource |
attributes()
Returns the related attributes. |
abstract int |
freq()
Returns term frequency in the current document, or 1 if the field was indexed with FieldInfo.IndexOptions.DOCS_ONLY . |
Methods inherited from class org.apache.lucene.search.DocIdSetIterator |
---|
advance, docID, nextDoc |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int FLAG_NONE
TermsEnum.docs(Bits,DocsEnum,int)
if you don't
require term frequencies in the returned enum. When passed to
TermsEnum.docsAndPositions(Bits,DocsAndPositionsEnum,int)
means
that no offsets and payloads will be returned.
public static final int FLAG_FREQS
TermsEnum.docs(Bits,DocsEnum,int)
if you require term frequencies in the returned enum.
Constructor Detail |
---|
protected DocsEnum()
Method Detail |
---|
public abstract int freq() throws IOException
FieldInfo.IndexOptions.DOCS_ONLY
. Do not call this before
DocIdSetIterator.nextDoc()
is first called, nor after DocIdSetIterator.nextDoc()
returns
DocIdSetIterator.NO_MORE_DOCS
.
NOTE: if the DocsEnum
was obtain with FLAG_NONE
,
the result of this method is undefined.
IOException
public AttributeSource attributes()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |