Overview | Package | Class | Use | Tree | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.lucene.spatial.prefix
Class TermQueryPrefixTreeStrategy

    java.lang.Object
      org.apache.lucene.spatial.SpatialStrategy
          org.apache.lucene.spatial.prefix.PrefixTreeStrategy
              org.apache.lucene.spatial.prefix.TermQueryPrefixTreeStrategy

    public class TermQueryPrefixTreeStrategy

extends PrefixTreeStrategy

A basic implementation of `PrefixTreeStrategy` using a large `TermsFilter` of all the cells from `SpatialPrefixTree.getCells(com.spatial4j.core.shape.Shape, int, boolean, boolean)`. 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.

WARNING: This API is experimental and might change in incompatible ways in the next release.

Field Summary

Fields inherited from class org.apache.lucene.spatial.prefix.PrefixTreeStrategy
`defaultFieldValuesArrayLen, distErrPct, FIELD_TYPE, grid, simplifyIndexedCells`

Fields inherited from class org.apache.lucene.spatial.SpatialStrategy
`ctx`

Constructor Summary
`TermQueryPrefixTreeStrategy(SpatialPrefixTree grid, String fieldName)`

Method Summary
`Filter` | `makeFilter(SpatialArgs args)` Make a Filter based principally on `SpatialOperation` and `Shape` from the supplied `args`.

Methods inherited from class org.apache.lucene.spatial.prefix.PrefixTreeStrategy
`createIndexableFields, createIndexableFields, getDistErrPct, getGrid, makeDistanceValueSource, setDefaultFieldValuesArrayLen, setDistErrPct`

Methods inherited from class org.apache.lucene.spatial.SpatialStrategy
`getFieldName, getSpatialContext, makeQuery, makeRecipDistanceValueSource, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### TermQueryPrefixTreeStrategy

    public TermQueryPrefixTreeStrategy(SpatialPrefixTree grid,
                                       String fieldName)

Method Detail

### makeFilter

    public Filter makeFilter(SpatialArgs args)

  Description copied from class: `SpatialStrategy`
  Make a Filter based principally on `SpatialOperation` and `Shape` from the supplied `args`.

  If a subclasses implements `SpatialStrategy.makeQuery(org.apache.lucene.spatial.query.SpatialArgs)` then this method could be simply:

      return new QueryWrapperFilter(makeQuery(args).getQuery());

  Specified by:
    `makeFilter` in class `SpatialStrategy`

Overview | Package | Class | Use | Tree | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.