public abstract class FieldsConsumer extends Object implements Closeable
The lifecycle is:
PostingsFormat.fieldsConsumer(SegmentWriteState)
.
addField(FieldInfo)
is called,
returning a TermsConsumer
for the field.
close()
d.
Modifier | Constructor and Description |
---|---|
protected |
FieldsConsumer()
Sole constructor.
|
Modifier and Type | Method and Description |
---|---|
abstract TermsConsumer |
addField(FieldInfo field)
Add a new field
|
abstract void |
close()
Called when we are done adding everything.
|
void |
merge(MergeState mergeState,
Fields fields)
Called during merging to merge all
Fields from
sub-readers. |
protected FieldsConsumer()
public abstract TermsConsumer addField(FieldInfo field) throws IOException
IOException
public abstract void close() throws IOException
close
in interface Closeable
IOException
public void merge(MergeState mergeState, Fields fields) throws IOException
Fields
from
sub-readers. This must recurse to merge all postings
(terms, docs, positions, etc.). A PostingsFormat
can override this default
implementation to do its own merging.IOException
Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.