public abstract class SpanQuery extends Query
| Constructor and Description |
|---|
SpanQuery() |
| Modifier and Type | Method and Description |
|---|---|
abstract SpanWeight |
createWeight(IndexSearcher searcher,
boolean needsScores)
Create a SpanWeight for this query
|
abstract String |
getField()
Returns the name of the field matched by this query.
|
static Map<Term,TermContext> |
getTermContexts(Collection<SpanWeight> weights)
Build a map of terms to termcontexts, for use in constructing SpanWeights
|
static Map<Term,TermContext> |
getTermContexts(SpanWeight... weights)
Build a map of terms to termcontexts, for use in constructing SpanWeights
|
Query |
rewrite(IndexReader reader)
Expert: called to re-write queries into primitive queries.
|
public abstract String getField()
public abstract SpanWeight createWeight(IndexSearcher searcher, boolean needsScores) throws IOException
createWeight in class Querysearcher - the IndexSearcher to be searched acrossneedsScores - if the query needs scoresIOException - on errorpublic static Map<Term,TermContext> getTermContexts(SpanWeight... weights)
public static Map<Term,TermContext> getTermContexts(Collection<SpanWeight> weights)
public Query rewrite(IndexReader reader) throws IOException
Queryrewrite in class QueryIOExceptionCopyright © 2000-2016 Apache Software Foundation. All Rights Reserved.