public class InstantiatedIndex
extends java.lang.Object
implements java.io.Serializable
WARNING: This contrib is experimental and the APIs may change without warning.
There are no read and write locks in this store.
InstantiatedIndexReader
InstantiatedIndexReader.isCurrent()
all the time
and InstantiatedIndexWriter
will attempt to update instances of the object graph in memory
at the same time as a searcher is reading from it.
Consider using InstantiatedIndex as if it was immutable.
Constructor and Description |
---|
InstantiatedIndex()
Creates an empty instantiated index for you to fill with data using an
InstantiatedIndexWriter . |
InstantiatedIndex(org.apache.lucene.index.IndexReader sourceIndexReader)
Creates a new instantiated index that looks just like the index in a specific state as represented by a reader.
|
InstantiatedIndex(org.apache.lucene.index.IndexReader sourceIndexReader,
java.util.Set<java.lang.String> fields)
Creates a new instantiated index that looks just like the index in a specific state as represented by a reader.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
org.apache.lucene.util.BitVector |
getDeletedDocuments() |
InstantiatedDocument[] |
getDocumentsByNumber() |
java.util.Map<java.lang.String,byte[]> |
getNormsByFieldNameAndDocumentNumber() |
InstantiatedTerm[] |
getOrderedTerms() |
java.util.Map<java.lang.String,java.util.Map<java.lang.String,InstantiatedTerm>> |
getTermsByFieldAndText() |
long |
getVersion() |
InstantiatedIndexReader |
indexReaderFactory() |
InstantiatedIndexWriter |
indexWriterFactory(org.apache.lucene.analysis.Analyzer analyzer,
boolean create) |
public InstantiatedIndex()
InstantiatedIndexWriter
.public InstantiatedIndex(org.apache.lucene.index.IndexReader sourceIndexReader) throws java.io.IOException
sourceIndexReader
- the source index this new instantiated index will be copied from.java.io.IOException
- if the source index is not optimized, or when accessing the source.public InstantiatedIndex(org.apache.lucene.index.IndexReader sourceIndexReader, java.util.Set<java.lang.String> fields) throws java.io.IOException
sourceIndexReader
- the source index this new instantiated index will be copied from.fields
- fields to be added, or null for alljava.io.IOException
- if the source index is not optimized, or when accessing the source.public InstantiatedIndexWriter indexWriterFactory(org.apache.lucene.analysis.Analyzer analyzer, boolean create) throws java.io.IOException
java.io.IOException
public InstantiatedIndexReader indexReaderFactory() throws java.io.IOException
java.io.IOException
public void close() throws java.io.IOException
java.io.IOException
public java.util.Map<java.lang.String,java.util.Map<java.lang.String,InstantiatedTerm>> getTermsByFieldAndText()
public InstantiatedTerm[] getOrderedTerms()
public InstantiatedDocument[] getDocumentsByNumber()
public java.util.Map<java.lang.String,byte[]> getNormsByFieldNameAndDocumentNumber()
public org.apache.lucene.util.BitVector getDeletedDocuments()
public long getVersion()
Copyright © 2000-2019 Apache Software Foundation. All Rights Reserved.