|
GEOS 3.6.2
|
#include <UnaryUnionOp.h>
Public Member Functions | |
| template<class T> | |
| UnaryUnionOp (const T &geoms, geom::GeometryFactory &geomFactIn) | |
| template<class T> | |
| UnaryUnionOp (const T &geoms) | |
| UnaryUnionOp (const geom::Geometry &geom) | |
| std::auto_ptr< geom::Geometry > | Union () |
| Gets the union of the input geometries. | |
Static Public Member Functions | |
| template<typename T> | |
| static std::auto_ptr< geom::Geometry > | Union (const T &geoms) |
| template<class T> | |
| static std::auto_ptr< geom::Geometry > | Union (const T &geoms, geom::GeometryFactory &geomFact) |
| static std::auto_ptr< geom::Geometry > | Union (const geom::Geometry &geom) |
Unions a collection of Geometry or a single Geometry (which may be a collection) together. By using this special-purpose operation over a collection of geometries it is possible to take advantage of various optimizations to improve performance. Heterogeneous GeometryCollections are fully supported.
The result obeys the following contract:
Polygonss has the effect of merging the areas (i.e. the same effect as iteratively unioning all individual polygons together).LineStrings has the effect of fully noding and dissolving the input linework. In this context "fully noded" means that there will be a node or endpoint in the output for every endpoint or line segment crossing in the input. "Dissolved" means that any duplicate (e.g. coincident) line segments or portions of line segments will be reduced to a single line segment in the output. * This is consistent with the semantics of the Geometry#union(Geometry) operation. If merged linework is required, the LineMerger class can be used.Pointss has the effect of merging al identical points (producing a set with no duplicates).UnaryUnion always operates on the individual components of MultiGeometries. So it is possible to use it to "clean" invalid self-intersecting MultiPolygons (although the polygon components must all still be individually valid.)
| std::auto_ptr< geom::Geometry > geos::operation::geounion::UnaryUnionOp::Union | ( | ) |
Gets the union of the input geometries.
If no input geometries were provided, a POINT EMPTY is returned.