WARNING: Version 5.x has passed its EOL date.
This documentation is no longer being maintained and may be removed. If you are running this version, we strongly advise you to upgrade. For the latest information, see the current release documentation.
Geo Hash Cell Query Usageedit
Fluent DSL exampleedit
q .GeoHashCell(c => c .Name("named_query") .Boost(1.1) .Field(p=>p.Location) .Location(new GeoLocation(13.4080, 52.5186)) .Neighbors() .Precision(Nest.Distance.Meters(3)) )
Object Initializer syntax exampleedit
new GeoHashCellQuery { Boost = 1.1, Name = "named_query", Field = Infer.Field<Project>(p=>p.Location), Location = new GeoLocation(13.4080, 52.5186), Neighbors = true, Precision = Nest.Distance.Meters(3) }
Example json output.
{ "geohash_cell": { "_name": "named_query", "boost": 1.1, "precision": "3.0m", "neighbors": true, "location": { "lat": 13.408, "lon": 52.5186 } } }