Class TermsConsumer
Abstract API that consumes terms for an individual field.
The lifecycle is:
- TermsConsumer is returned for each field by AddField(FieldInfo).
- TermsConsumer returns a PostingsConsumer for each term in StartTerm(BytesRef).
- When the producer (e.g. IndexWriter) is done adding documents for the term, it calls FinishTerm(BytesRef, TermStats), passing in the accumulated term statistics.
- Producer calls Finish(Int64, Int64, Int32) with the accumulated collection statistics when it is finished adding terms to the field.
@lucene.experimental
Inheritance
System.Object
TermsConsumer
Assembly: DistributedLucene.Net.dll
Syntax
public abstract class TermsConsumer : object
Constructors
Name | Description |
---|---|
TermsConsumer() | Sole constructor. (For invocation by subclass constructors, typically implicit.) |
Properties
Name | Description |
---|---|
Comparer | Gets the IComparer<BytesRef> used to sort terms before feeding to this API. |
Methods
Name | Description |
---|---|
Finish(Int64, Int64, Int32) | Called when we are done adding terms to this field.
|
FinishTerm(BytesRef, TermStats) | Finishes the current term; numDocs must be > 0.
|
Merge(MergeState, IndexOptions, TermsEnum) | Default merge impl. |
StartTerm(BytesRef) | Starts a new term in this field; this may be called with no corresponding call to finish if the term had no docs. |