|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
PrefixMap
.
@Deprecated public interface PrefixMap
A map from prefixes to term intervals (and possibly viceversa).
Given a list of terms in lexicographic order numbered from 0, we can ask, given a prefix, which interval of terms starts with the given prefix. This information is very useful to satisfy prefix queries (e.g., monitor*) with a brute-force approach, that is, or-ing the document iterators corresponding to each term. The interval is more useful than the actual list of terms starting with the prefix, as it allows to build directly the composed iterator.
Optionally, a prefix map may provide the opposite service: given an interval of terms, it
may provide the maximum common prefix. This feature can be checked for by calling hasPrefixes()
.
Method Summary | |
---|---|
Interval |
getInterval(CharSequence prefix)
Deprecated. Returns the interval of terms starting with the given prefix. |
CharSequence |
getPrefix(Interval interval)
Deprecated. Returns the maximum prefix common to all terms in the given nonempty interval (optional operation). |
MutableString |
getPrefix(Interval interval,
MutableString prefix)
Deprecated. Writes in the given mutable string the maximum prefix common to all terms in the given nonempty interval (optional operation). |
boolean |
hasPrefixes()
Deprecated. Returns true if this prefix map supports prefix retrieval. |
int |
size()
Deprecated. Returns the number of terms in this prefix map. |
Method Detail |
---|
Interval getInterval(CharSequence prefix)
prefix
- a prefix.
prefix
(Intervals.EMPTY_INTERVAL
in case no term starts with prefix
).boolean hasPrefixes()
CharSequence getPrefix(Interval interval)
interval
- an interval.
MutableString getPrefix(Interval interval, MutableString prefix)
interval
- an interval.prefix
- a mutable string that will be filled with the maximum prefix common to all terms in the given nonempty interval.
prefix
.int size()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |