public abstract class SpatialQueryBuilder extends Object
Constructor and Description |
---|
SpatialQueryBuilder() |
Modifier and Type | Method and Description |
---|---|
static Query |
buildSpatialQueryByHash(double latitude,
double longitude,
double radius,
String fieldName)
Returns a Lucene Query which relies on Hibernate Search Spatial
spatial hash indexation to find candidate documents and filter its results
in radius range by a DistanceFilter
|
static Query |
buildSpatialQueryByRange(double latitude,
double longitude,
double radius,
String fieldName)
Returns a Lucene Query which relies on Hibernate Search Spatial
double range indexation to filter document at radius and filter its results
by a fine DistanceFilter
|
public static Query buildSpatialQueryByHash(double latitude, double longitude, double radius, String fieldName)
latitude
- WGS84 latitude of the center of the searchlongitude
- WGS84 longitude of the center of the searchradius
- distance max to center in kmfieldName
- name of the Lucene Field implementing CoordinatesQuery
,
Coordinates
public static Query buildSpatialQueryByRange(double latitude, double longitude, double radius, String fieldName)
latitude
- WGS84 latitude of the center of the searchlongitude
- WGS84 longitude of the center of the searchradius
- distance max to center in kmfieldName
- name of the Lucene Field implementing CoordinatesQuery
,
Coordinates
Copyright © 2006-2017 Red Hat, Inc. All Rights Reserved