Class GeometrySimplifier.MultiPolygonSimplifier

java.lang.Object
org.elasticsearch.geometry.simplify.GeometrySimplifier<MultiPolygon>
org.elasticsearch.geometry.simplify.GeometrySimplifier.MultiPolygonSimplifier
Enclosing class:
GeometrySimplifier<T extends Geometry>

public static class GeometrySimplifier.MultiPolygonSimplifier extends GeometrySimplifier<MultiPolygon>
This class wraps a collection of Polygon simplifiers. It does not make use of its own simplifier capabilities. The largest inner polygon is simplified to the specified maxPoints, while the rest are simplified to a maxPoints value that is a fraction of their size compared to the largest size.

Note that this simplifier cannot work in streaming mode. Since a MultiPolygon can contain more than one polygon, the consume(Point) method would not know which polygon to add to. If you need to use the streaming mode, separate the multi-polygon into individual polygons and use the Polygon simplifier on each individually.