public class TermQueryPrefixTreeStrategy extends PrefixTreeStrategy
PrefixTreeStrategy using a large
TermInSetQuery of all the cells from
SpatialPrefixTree.getTreeCellIterator(org.locationtech.spatial4j.shape.Shape, int).
It only supports the search of indexed Point shapes.
The precision of query shapes (distErrPct) is an important factor in using this Strategy. If the precision is too precise then it will result in many terms which will amount to a slower query.
PrefixTreeStrategy.ShapeTokenStream| Modifier and Type | Field and Description |
|---|---|
protected boolean |
simplifyIndexedCells |
defaultFieldValuesArrayLen, distErrPct, FIELD_TYPE, grid, pointsOnlyctx| Constructor and Description |
|---|
TermQueryPrefixTreeStrategy(SpatialPrefixTree grid,
String fieldName) |
| Modifier and Type | Method and Description |
|---|---|
Query |
makeQuery(SpatialArgs args)
|
protected CellToBytesRefIterator |
newCellToBytesRefIterator() |
calcFacets, createCellIteratorToIndex, createIndexableFields, createIndexableFields, createIndexableFields, getDistErrPct, getGrid, isPointShape, isPointsOnly, makeDistanceValueSource, setDefaultFieldValuesArrayLen, setDistErrPct, setPointsOnly, tokenStreamgetFieldName, getSpatialContext, makeDistanceValueSource, makeRecipDistanceValueSource, toStringpublic TermQueryPrefixTreeStrategy(SpatialPrefixTree grid, String fieldName)
protected CellToBytesRefIterator newCellToBytesRefIterator()
newCellToBytesRefIterator in class PrefixTreeStrategypublic Query makeQuery(SpatialArgs args)
SpatialStrategySpatialOperation
and Shape from the supplied args. It should be constant scoring of 1.makeQuery in class SpatialStrategyCopyright © 2000-2020 Apache Software Foundation. All Rights Reserved.