public class ConnectedSpatialContext extends Object implements SpatialContext
Constructor and Description |
---|
ConnectedSpatialContext(QueryBuildingContext context,
ConnectedQueryBuilder queryBuilder) |
Modifier and Type | Method and Description |
---|---|
SpatialContext |
boostedTo(float boost)
Boost the query to a given value
Most of the time positive float:
- lower than 1 to diminish the weight
- higher than 1 to increase the weight
Could be negative but not unless you understand what is going on (advanced)
|
SpatialContext |
filteredBy(org.apache.lucene.search.Filter filter)
Filter the query results with the Filter instance
|
SpatialMatchingContext |
onCoordinates(String field)
An entity can have multiple
Spatial annotations defining
different sets of coordinates. |
SpatialMatchingContext |
onDefaultCoordinates()
Used to create Spatial Queries on the default coordinates of
an entity.
|
SpatialContext |
withConstantScore()
All results matching the query have a constant score equals to the boost
FIXME is that true?
|
public ConnectedSpatialContext(QueryBuildingContext context, ConnectedQueryBuilder queryBuilder)
public SpatialMatchingContext onCoordinates(String field)
SpatialContext
Spatial
annotations defining
different sets of coordinates.
Each non-default Spatial instance has a name to identify it,
use this method to pick one of these non-default coordinate fields.onCoordinates
in interface SpatialContext
field
- The name of the set of coordinates to target for the querypublic SpatialMatchingContext onDefaultCoordinates()
SpatialContext
Spatial
is being used
without defining a custom value for Spatial#name()
.onDefaultCoordinates
in interface SpatialContext
public SpatialContext boostedTo(float boost)
QueryCustomization
boostedTo
in interface QueryCustomization<SpatialContext>
public SpatialContext withConstantScore()
QueryCustomization
withConstantScore
in interface QueryCustomization<SpatialContext>
public SpatialContext filteredBy(org.apache.lucene.search.Filter filter)
QueryCustomization
filteredBy
in interface QueryCustomization<SpatialContext>
Copyright © 2006–2013 Hibernate. All rights reserved.