public abstract class SpanQuery extends Query
| Constructor and Description |
|---|
SpanQuery() |
| Modifier and Type | Method and Description |
|---|---|
protected Weight |
createWeight(Searcher searcher)
Expert: Constructs an appropriate Weight implementation for this query.
|
abstract java.lang.String |
getField()
Returns the name of the field matched by this query.
|
PayloadSpans |
getPayloadSpans(IndexReader reader)
Returns the matches for this query in an index, including access to any
Payloads at those
positions. |
abstract Spans |
getSpans(IndexReader reader)
Expert: Returns the matches for this query in an index.
|
abstract java.util.Collection |
getTerms()
Deprecated.
use extractTerms instead
|
clone, combine, extractTerms, getBoost, getSimilarity, mergeBooleanQueries, rewrite, setBoost, toString, toString, weightpublic abstract Spans getSpans(IndexReader reader) throws java.io.IOException
java.io.IOExceptionpublic PayloadSpans getPayloadSpans(IndexReader reader) throws java.io.IOException
Payloads at those
positions. Implementing classes that want access to the payloads will need to implement this.reader - The IndexReader to use to get spans/payloadsjava.io.IOException - if there is an error accessing the payload
WARNING: The status of the Payloads feature is experimental.
The APIs introduced here might change in the future and will not be
supported anymore in such a case.public abstract java.lang.String getField()
public abstract java.util.Collection getTerms()
Query.extractTerms(Set)protected Weight createWeight(Searcher searcher) throws java.io.IOException
QueryOnly implemented by primitive queries, which re-write to themselves.
createWeight in class Queryjava.io.IOExceptionCopyright © 2000-2014 Apache Software Foundation. All Rights Reserved.