0

Can someone give me some guide about how to use GeoShapeQuery in java?

I want some code like this:

Query geoShape = GeoShapeQuery.of(f->f.field(ConvertUtils.FULL_GEO)
                        .shape(s->s.relation(GeoShapeRelation.Contains).shape(shape)))._toQuery();
Query bool = BoolQuery.of(b->b
                        .filter(geoShape)
                        .should(rankFeature)
                        )._toQuery();

the above code is from here

but I want to know how to use it.

I am using ElasticSearch 8.7 vesion, and I have google for couple of hours,and still can't get the tutorial about using GeoShapeQuery in java

I am tying the use GeoShapeQuery to find out whether a spot is in the area or not

hld942614
  • 1
  • 1
  • Which part of the code above does not work for you? Do you get any errors? Does it yield unexpected results? – Hulk May 16 '23 at 03:22
  • I got this error:"FULL_GEO cannot be resolved or is not a field",I also want some document about how to use GeoShapeQuery. – hld942614 May 18 '23 at 07:42

0 Answers0