SearchSortGeoDistance
class SearchSortGeoDistance extends SearchSort implements JsonSerializable (View source)
Sort by a location and unit in the hits.
Methods
static SearchSortGeoDistance
geoDistance(string $field, float $longitude, float $latitude)
Sort by geo location.
from
SearchSort
descending(bool $descending)
Direction of the sort
unit(string $unit)
Name of the units
Details
static SearchSortId
id()
Sort by the document identifier.
static SearchSortScore
score()
Sort by the hit score.
static SearchSortField
field(string $field)
Sort by a field in the hits.
static SearchSortGeoDistance
geoDistance(string $field, float $longitude, float $latitude)
Sort by geo location.
SearchSortGeoDistance
descending(bool $descending)
Direction of the sort
SearchSortGeoDistance
unit(string $unit)
Name of the units