- java.lang.Object
-
- org.apache.lucene.util.fst.OffHeapFSTStore
-
- All Implemented Interfaces:
Accountable
,FSTReader
,FSTStore
public final class OffHeapFSTStore extends java.lang.Object implements FSTStore
Provides off heap storage of finite state machine (FST), using underlying index input instead of byte store on heap
-
-
Field Summary
Fields Modifier and Type Field Description private static long
BASE_RAM_BYTES_USED
private IndexInput
in
private long
numBytes
private long
offset
-
Fields inherited from interface org.apache.lucene.util.Accountable
NULL_ACCOUNTABLE
-
-
Constructor Summary
Constructors Constructor Description OffHeapFSTStore()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FST.BytesReader
getReverseBytesReader()
Get the reverse BytesReader for this FSTFSTStore
init(DataInput in, long numBytes)
Initialize the FSTStorelong
ramBytesUsed()
Return the memory usage of this object in bytes.long
size()
void
writeTo(DataOutput out)
Write this FST to another DataOutput-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.lucene.util.Accountable
getChildResources
-
-
-
-
Field Detail
-
BASE_RAM_BYTES_USED
private static final long BASE_RAM_BYTES_USED
-
in
private IndexInput in
-
offset
private long offset
-
numBytes
private long numBytes
-
-
Method Detail
-
init
public FSTStore init(DataInput in, long numBytes) throws java.io.IOException
Description copied from interface:FSTStore
Initialize the FSTStore
-
ramBytesUsed
public long ramBytesUsed()
Description copied from interface:Accountable
Return the memory usage of this object in bytes. Negative values are illegal.- Specified by:
ramBytesUsed
in interfaceAccountable
-
size
public long size()
-
getReverseBytesReader
public FST.BytesReader getReverseBytesReader()
Description copied from interface:FSTReader
Get the reverse BytesReader for this FST- Specified by:
getReverseBytesReader
in interfaceFSTReader
- Returns:
- the reverse BytesReader
-
writeTo
public void writeTo(DataOutput out) throws java.io.IOException
Description copied from interface:FSTReader
Write this FST to another DataOutput
-
-