public class SpanWildcardQuery extends SpanTermQuery
Modifier and Type | Field and Description |
---|---|
private int |
termLimit
Limit on the total number of terms matched
|
private static int |
TERMS_TO_REPORT
Limit on the number of terms to report on an error
|
Constructor and Description |
---|
SpanWildcardQuery(Term term)
Construct a SpanWildcardTermQuery matching expanded terms
|
SpanWildcardQuery(Term term,
int termLimit)
Construct a SpanWildcardTermQuery matching expanded terms, but
limiting the total number of terms matched.
|
Modifier and Type | Method and Description |
---|---|
Spans |
getSpans(IndexReader reader,
Searcher searcher)
Should never be called on the wildcard query itself, only on the
result of
rewrite(IndexReader) . |
int |
getTermLimit()
Retrieve the term limit this was constructed with
|
Query |
rewrite(IndexReader reader)
This method is actually the workhorse of the class.
|
protected boolean |
shouldSkipTerm(Term t)
Enables derived classes to skip certain terms in the index (e.g. stop
words, bi-grams, etc.)
|
String |
toString(String field) |
getField, getTerm, getTermLength, getTerms
createWeight, getSpanRecording, setSpanRecording
private int termLimit
private static final int TERMS_TO_REPORT
public SpanWildcardQuery(Term term)
public SpanWildcardQuery(Term term, int termLimit)
public int getTermLimit()
public Query rewrite(IndexReader reader) throws IOException
rewrite
in class Query
IOException
protected boolean shouldSkipTerm(Term t)
public Spans getSpans(IndexReader reader, Searcher searcher) throws IOException
rewrite(IndexReader)
.getSpans
in class SpanTermQuery
IOException
public String toString(String field)
toString
in class SpanTermQuery