public class ConnectedSortDistanceNoFieldContext extends AbstractConnectedSortContext implements SortDistanceNoFieldContext
queryContext, states
Constructor and Description |
---|
ConnectedSortDistanceNoFieldContext(QueryBuildingContext queryContext,
SortFieldStates states) |
Modifier and Type | Method and Description |
---|---|
SortDistanceFieldContext |
onField(String fieldName)
Order elements by distance computed from the coordinates carried by the given field.
|
getQueryContext, getStates
public ConnectedSortDistanceNoFieldContext(QueryBuildingContext queryContext, SortFieldStates states)
public SortDistanceFieldContext onField(String fieldName)
SortDistanceNoFieldContext
The distance is computed between the value of the given field (which must be
a Spatial
field) and reference coordinates, to be provided in the
next context
.
onField
in interface SortDistanceNoFieldContext
fieldName
- The name of the index field carrying the spatial coordinates.Copyright © 2006-2017 Red Hat, Inc. All Rights Reserved