private class PerFieldPostingsFormat.FieldsWriter extends FieldsConsumer
Modifier and Type | Field and Description |
---|---|
(package private) java.util.List<java.io.Closeable> |
toClose |
(package private) SegmentWriteState |
writeState |
Constructor and Description |
---|
FieldsWriter(SegmentWriteState writeState) |
Modifier and Type | Method and Description |
---|---|
private java.util.Map<PostingsFormat,PerFieldPostingsFormat.FieldsGroup> |
buildFieldsGroupMapping(java.lang.Iterable<java.lang.String> indexedFieldNames) |
void |
close() |
void |
merge(MergeState mergeState,
NormsProducer norms)
Merges in the fields from the readers in
mergeState . |
void |
write(Fields fields,
NormsProducer norms)
Write all fields, terms and postings.
|
final SegmentWriteState writeState
final java.util.List<java.io.Closeable> toClose
public FieldsWriter(SegmentWriteState writeState)
public void write(Fields fields, NormsProducer norms) throws java.io.IOException
FieldsConsumer
Notes:
write
in class FieldsConsumer
java.io.IOException
public void merge(MergeState mergeState, NormsProducer norms) throws java.io.IOException
FieldsConsumer
mergeState
. The default implementation skips
and maps around deleted documents, and calls FieldsConsumer.write(Fields,NormsProducer)
.
Implementations can override this method for more sophisticated
merging (bulk-byte copying, etc).merge
in class FieldsConsumer
java.io.IOException
private java.util.Map<PostingsFormat,PerFieldPostingsFormat.FieldsGroup> buildFieldsGroupMapping(java.lang.Iterable<java.lang.String> indexedFieldNames)
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class FieldsConsumer
java.io.IOException