java.lang.Object
org.apache.lucene.store.IOContext
IOContext holds additional details on the merge/search context. A IOContext object can never be
initialized as null as passed as a parameter to either
Directory.openInput(String, IOContext) or Directory.createOutput(String, IOContext)-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumContext is a enumerator which specifies the context in which the Directory is being used for. -
Field Summary
FieldsModifier and TypeFieldDescriptionfinal IOContext.ContextAn object of a enumerator Context typestatic final IOContextfinal FlushInfofinal booleanThis flag is used for files that are a small fraction of the total index size and are expected to be heavily accessed in random-access fashion.static final IOContextfinal MergeInfostatic final IOContextfinal booleanThis flag indicates that the file will be opened, then fully read sequentially then closed.static final IOContext -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateIOContext(boolean readOnce, boolean load) IOContext(IOContext.Context context) privateIOContext(IOContext.Context context, MergeInfo mergeInfo) This constructor is used to initialize aIOContextinstance with a new value for the readOnce variable. -
Method Summary
-
Field Details
-
context
An object of a enumerator Context type -
mergeInfo
-
flushInfo
-
readOnce
public final boolean readOnceThis flag indicates that the file will be opened, then fully read sequentially then closed. -
load
public final boolean loadThis flag is used for files that are a small fraction of the total index size and are expected to be heavily accessed in random-access fashion. SomeDirectoryimplementations may choose to load such files into physical memory (e.g. Java heap) as a way to provide stronger guarantees on query latency. -
DEFAULT
-
READONCE
-
READ
-
LOAD
-
-
Constructor Details
-
IOContext
public IOContext() -
IOContext
-
IOContext
-
IOContext
private IOContext(boolean readOnce, boolean load) -
IOContext
-
IOContext
-
IOContext
This constructor is used to initialize aIOContextinstance with a new value for the readOnce variable.
-
-
Method Details