Class SparsePolygonUnion


  • public class SparsePolygonUnion
    extends java.lang.Object
    Unions a set of polygonal geometries by partitioning them into connected sets of polygons. This works best for a sparse set of polygons. Sparse means that if the geometries are partioned into connected sets, the number of sets is a significant fraction of the total number of geometries. The algorithm used provides performance and memory advantages over the CascadedPolygonUnion algorithm. It also has the advantage that it does not alter input geometries which do not intersect any other input geometry.

    Non-sparse sets will work, but may be slower than using cascaded union.

    Author:
    mdavis
    • Constructor Summary

      Constructors 
      Constructor Description
      SparsePolygonUnion​(java.util.Collection<org.locationtech.jts.geom.Geometry> polys)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.locationtech.jts.geom.Geometry union()  
      static org.locationtech.jts.geom.Geometry union​(java.util.Collection geoms)  
      static org.locationtech.jts.geom.Geometry union​(org.locationtech.jts.geom.Geometry geoms)  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SparsePolygonUnion

        public SparsePolygonUnion​(java.util.Collection<org.locationtech.jts.geom.Geometry> polys)
    • Method Detail

      • union

        public static org.locationtech.jts.geom.Geometry union​(java.util.Collection geoms)
      • union

        public static org.locationtech.jts.geom.Geometry union​(org.locationtech.jts.geom.Geometry geoms)
      • union

        public org.locationtech.jts.geom.Geometry union()