public final class VersionBlockTreeTermsWriter extends FieldsConsumer
BlockTreeTermsWriter
, except it also stores a version per term, and adds a method to its TermsEnum
implementation to seekExact only if the version is >= the specified version. The version is added to the terms index to avoid seeking if
no term in the block has a high enough version. The term blocks file is .tiv and the terms index extension is .tipv.Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_MAX_BLOCK_SIZE
Suggested default value for the
maxItemsInBlock parameter to VersionBlockTreeTermsWriter(SegmentWriteState,PostingsWriterBase,int,int) . |
static int |
DEFAULT_MIN_BLOCK_SIZE
Suggested default value for the
minItemsInBlock parameter to VersionBlockTreeTermsWriter(SegmentWriteState,PostingsWriterBase,int,int) . |
static int |
VERSION_CURRENT
Current terms format.
|
static int |
VERSION_START
Initial terms format.
|
Constructor and Description |
---|
VersionBlockTreeTermsWriter(SegmentWriteState state,
PostingsWriterBase postingsWriter,
int minItemsInBlock,
int maxItemsInBlock)
Create a new writer.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
write(Fields fields,
NormsProducer norms) |
merge
public static final int DEFAULT_MIN_BLOCK_SIZE
minItemsInBlock
parameter to VersionBlockTreeTermsWriter(SegmentWriteState,PostingsWriterBase,int,int)
.public static final int DEFAULT_MAX_BLOCK_SIZE
maxItemsInBlock
parameter to VersionBlockTreeTermsWriter(SegmentWriteState,PostingsWriterBase,int,int)
.public static final int VERSION_START
public static final int VERSION_CURRENT
public VersionBlockTreeTermsWriter(SegmentWriteState state, PostingsWriterBase postingsWriter, int minItemsInBlock, int maxItemsInBlock) throws IOException
IOException
public void write(Fields fields, NormsProducer norms) throws IOException
write
in class FieldsConsumer
IOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class FieldsConsumer
IOException
Copyright © 2000-2021 Apache Software Foundation. All Rights Reserved.