org.apache.lucene.spatial.prefix

## Class AbstractPrefixTreeQuery

- java.lang.Object
- - org.apache.lucene.search.Query
  - - org.apache.lucene.spatial.prefix.AbstractPrefixTreeQuery

- Direct Known Subclasses:
    AbstractVisitingPrefixTreeQuery, ContainsPrefixTreeQuery

      public abstract class AbstractPrefixTreeQuery
      extends Query

  Base class for Lucene Queries on SpatialPrefixTree fields.
  NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.

- - ### Nested Class Summary

    Nested Classes
    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`.

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected int` | `detailLevel`
    `protected String` | `fieldName`
    `protected SpatialPrefixTree` | `grid`
    `protected org.locationtech.spatial4j.shape.Shape` | `queryShape`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `AbstractPrefixTreeQuery(org.locationtech.spatial4j.shape.Shape queryShape, String fieldName, SpatialPrefixTree grid, int detailLevel)`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Weight` | `createWeight(IndexSearcher searcher, boolean needsScores, float boost)`
    `boolean` | `equals(Object o)`
    `protected abstract DocIdSet` | `getDocIdSet(LeafReaderContext context)`
    `int` | `hashCode()`

    - ### Methods inherited from class org.apache.lucene.search.Query

      `classHash, rewrite, sameClassAs, toString, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### queryShape

          protected final org.locationtech.spatial4j.shape.Shape queryShape

    - #### fieldName

          protected final String fieldName

    - #### grid

          protected final SpatialPrefixTree grid

    - #### detailLevel

          protected final int detailLevel

  - ### Constructor Detail

    - #### AbstractPrefixTreeQuery

          public AbstractPrefixTreeQuery(org.locationtech.spatial4j.shape.Shape queryShape,
                                         String fieldName,
                                         SpatialPrefixTree grid,
                                         int detailLevel)

  - ### Method Detail

    - #### equals

          public boolean equals(Object o)

      Specified by:
        `equals` in class `Query`

    - #### hashCode

          public int hashCode()

      Specified by:
        `hashCode` in class `Query`

    - #### createWeight

          public Weight createWeight(IndexSearcher searcher,
                                     boolean needsScores,
                                     float boost)
                              throws IOException

      Overrides:
        `createWeight` in class `Query`
      Throws:
        `IOException`

    - #### getDocIdSet

          protected abstract DocIdSet getDocIdSet(LeafReaderContext context)
                                           throws IOException

      Throws:
        `IOException`

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