final class TermInfosReader
extends Object
Modifier and Type | Field and Description |
---|---|
private Directory |
directory |
private ThreadLocal |
enumerators |
private FieldInfos |
fieldInfos |
private SegmentTermEnum |
indexEnum |
private TermInfo[] |
indexInfos |
private long[] |
indexPointers |
private Term[] |
indexTerms |
private SegmentTermEnum |
origEnum |
private String |
segment |
private long |
size |
Constructor and Description |
---|
TermInfosReader(Directory dir,
String seg,
FieldInfos fis) |
Modifier and Type | Method and Description |
---|---|
(package private) void |
close() |
private void |
ensureIndexIsRead() |
(package private) Term |
get(int position)
Returns the nth term in the set.
|
(package private) TermInfo |
get(Term term)
Returns the TermInfo for a Term in the set, or null.
|
private SegmentTermEnum |
getEnum() |
private int |
getIndexOffset(Term term)
Returns the offset of the greatest index entry which is less than or equal to term.
|
(package private) long |
getPosition(Term term)
Returns the position of a Term in the set or -1.
|
int |
getSkipInterval() |
private Term |
scanEnum(int position) |
private TermInfo |
scanEnum(Term term)
Scans within block for matching term.
|
private void |
seekEnum(int indexOffset) |
(package private) long |
size()
Returns the number of term/value pairs in the set.
|
SegmentTermEnum |
terms()
Returns an enumeration of all the Terms and TermInfos in the set.
|
SegmentTermEnum |
terms(Term term)
Returns an enumeration of terms starting at or after the named term.
|
private Directory directory
private String segment
private FieldInfos fieldInfos
private ThreadLocal enumerators
private SegmentTermEnum origEnum
private long size
private Term[] indexTerms
private TermInfo[] indexInfos
private long[] indexPointers
private SegmentTermEnum indexEnum
TermInfosReader(Directory dir, String seg, FieldInfos fis) throws IOException
IOException
public int getSkipInterval()
final void close() throws IOException
IOException
final long size()
private SegmentTermEnum getEnum()
private void ensureIndexIsRead() throws IOException
IOException
private final int getIndexOffset(Term term)
private final void seekEnum(int indexOffset) throws IOException
IOException
TermInfo get(Term term) throws IOException
IOException
private final TermInfo scanEnum(Term term) throws IOException
IOException
final Term get(int position) throws IOException
IOException
private final Term scanEnum(int position) throws IOException
IOException
final long getPosition(Term term) throws IOException
IOException
public SegmentTermEnum terms()
public SegmentTermEnum terms(Term term) throws IOException
IOException