public abstract class AbstractPrefixTreeQuery extends Query
Modifier and Type | Class and Description |
---|---|
class |
AbstractPrefixTreeQuery.BaseTermsEnumTraverser
Holds transient state and docid collecting utility methods as part of
traversing a
TermsEnum for a LeafReaderContext . |
Modifier and Type | Field and Description |
---|---|
protected int |
detailLevel |
protected java.lang.String |
fieldName |
protected SpatialPrefixTree |
grid |
protected org.locationtech.spatial4j.shape.Shape |
queryShape |
Constructor and Description |
---|
AbstractPrefixTreeQuery(org.locationtech.spatial4j.shape.Shape queryShape,
java.lang.String fieldName,
SpatialPrefixTree grid,
int detailLevel) |
Modifier and Type | Method and Description |
---|---|
Weight |
createWeight(IndexSearcher searcher,
boolean needsScores,
float boost)
Expert: Constructs an appropriate Weight implementation for this query.
|
boolean |
equals(java.lang.Object o)
Override and implement query instance equivalence properly in a subclass.
|
protected abstract DocIdSet |
getDocIdSet(LeafReaderContext context) |
int |
hashCode()
Override and implement query hash code properly in a subclass.
|
protected final org.locationtech.spatial4j.shape.Shape queryShape
protected final java.lang.String fieldName
protected final SpatialPrefixTree grid
protected final int detailLevel
public AbstractPrefixTreeQuery(org.locationtech.spatial4j.shape.Shape queryShape, java.lang.String fieldName, SpatialPrefixTree grid, int detailLevel)
public boolean equals(java.lang.Object o)
Query
QueryCache
works properly.
Typically a query will be equal to another only if it's an instance of
the same class and its document-filtering properties are identical that other
instance. Utility methods are provided for certain repetitive code.equals
in class Query
Query.sameClassAs(Object)
,
Query.classHash()
public int hashCode()
Query
QueryCache
works properly.hashCode
in class Query
Query.equals(Object)
public Weight createWeight(IndexSearcher searcher, boolean needsScores, float boost) throws java.io.IOException
Query
Only implemented by primitive queries, which re-write to themselves.
createWeight
in class Query
needsScores
- True if document scores (Scorer.score()
) are needed.boost
- The boost that is propagated by the parent queries.java.io.IOException
protected abstract DocIdSet getDocIdSet(LeafReaderContext context) throws java.io.IOException
java.io.IOException
Copyright © 2000–2019 The Apache Software Foundation. All rights reserved.