org.hibernate.search.query.dsl

## Interface SpatialContext

- All Superinterfaces:
    QueryCustomization<SpatialContext>, SpatialMatchingContext
  All Known Implementing Classes:
    ConnectedSpatialContext

      public interface SpatialContext
      extends QueryCustomization<SpatialContext>, SpatialMatchingContext

  Author:
    Emmanuel Bernard

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `SpatialMatchingContext` | `onField(String fieldName)` Used to select the spatial field/coordinates used for this query.

    - ### Methods inherited from interface org.hibernate.search.query.dsl.QueryCustomization

      `boostedTo, filteredBy, withConstantScore`

    - ### Methods inherited from interface org.hibernate.search.query.dsl.SpatialMatchingContext

      `within`

- - ### Method Detail

    - #### onField

          SpatialMatchingContext onField(String fieldName)

      Used to select the spatial field/coordinates used for this query. If not specified, the default field (`Spatial.COORDINATES_DEFAULT_FIELD`) is used.

      Note: An entity can have multiple `Spatial` annotations defining different sets of coordinates. Each non-default `Spatial` instance has a name to identify it. Use this method to specify the targeted coordinate field.

      Parameters:
        `fieldName` - The name of the set of coordinates to target for the query
      Returns:
        `SpatialMatchingContext` instance for continuation

Copyright © 2006-2017 Red Hat, Inc. All Rights Reserved