[geos-commits] r2930 - in trunk: . capi
svn_geos at osgeo.org
svn_geos at osgeo.org
Sun Feb 28 13:55:45 EST 2010
Author: strk
Date: 2010-02-28 13:55:44 -0500 (Sun, 28 Feb 2010)
New Revision: 2930
Modified:
trunk/NEWS
trunk/capi/geos_c.cpp
trunk/capi/geos_c.h.in
Log:
Provide non-rehentrant version of empty geometries constructors
Modified: trunk/NEWS
===================================================================
--- trunk/NEWS 2010-02-28 17:02:29 UTC (rev 2929)
+++ trunk/NEWS 2010-02-28 18:55:44 UTC (rev 2930)
@@ -3,8 +3,8 @@
- New things:
- CAPI: GEOSisValidDetail: tell state, reason & location apart
- CAPI: GEOSContext_setNoticeHandler_r, GEOSContext_setErrorHandler_r
- - CAPI: GEOSGeom_createEmptyPoint_r, GEOSGeom_createEmptyLineString_r
- GEOSGeom_createEmptyPolygon_r, GEOSGeom_createEmptyCollection_r
+ - CAPI: GEOSGeom_createEmptyPoint, GEOSGeom_createEmptyLineString
+ GEOSGeom_createEmptyPolygon, GEOSGeom_createEmptyCollection
- CAPI: GEOSGeom_extractUniquePoints
- CAPI: GEOSGetGeometryN support for single geometries
- CAPI: GEOSPolygonize_full to return all informations computed by
Modified: trunk/capi/geos_c.cpp
===================================================================
--- trunk/capi/geos_c.cpp 2010-02-28 17:02:29 UTC (rev 2929)
+++ trunk/capi/geos_c.cpp 2010-02-28 18:55:44 UTC (rev 2930)
@@ -943,5 +943,28 @@
return GEOSGeom_extractUniquePoints_r(handle, g);
}
+geos::geom::Geometry *
+GEOSGeom_createEmptyCollection(int type)
+{
+ return GEOSGeom_createEmptyCollection_r(handle, type);
+}
+geos::geom::Geometry *
+GEOSGeom_createEmptyPoint()
+{
+ return GEOSGeom_createEmptyPoint_r(handle);
+}
+
+geos::geom::Geometry *
+GEOSGeom_createEmptyLineString()
+{
+ return GEOSGeom_createEmptyLineString_r(handle);
+}
+
+geos::geom::Geometry *
+GEOSGeom_createEmptyPolygon()
+{
+ return GEOSGeom_createEmptyPolygon_r(handle);
+}
+
} /* extern "C" */
Modified: trunk/capi/geos_c.h.in
===================================================================
--- trunk/capi/geos_c.h.in 2010-02-28 17:02:29 UTC (rev 2929)
+++ trunk/capi/geos_c.h.in 2010-02-28 18:55:44 UTC (rev 2930)
@@ -413,8 +413,10 @@
***********************************************************************/
extern GEOSGeometry GEOS_DLL *GEOSGeom_createPoint(GEOSCoordSequence* s);
+extern GEOSGeometry GEOS_DLL *GEOSGeom_createEmptyPoint();
extern GEOSGeometry GEOS_DLL *GEOSGeom_createLinearRing(GEOSCoordSequence* s);
extern GEOSGeometry GEOS_DLL *GEOSGeom_createLineString(GEOSCoordSequence* s);
+extern GEOSGeometry GEOS_DLL *GEOSGeom_createEmptyLineString();
extern GEOSGeometry GEOS_DLL *GEOSGeom_createPoint_r(
GEOSContextHandle_t handle,
@@ -435,10 +437,12 @@
* The caller remains owner of the array, but pointed-to
* objects become ownership of the returned GEOSGeometry.
*/
+extern GEOSGeometry GEOS_DLL *GEOSGeom_createEmptyPolygon();
extern GEOSGeometry GEOS_DLL *GEOSGeom_createPolygon(GEOSGeometry* shell,
GEOSGeometry** holes, unsigned int nholes);
extern GEOSGeometry GEOS_DLL *GEOSGeom_createCollection(int type,
GEOSGeometry* *geoms, unsigned int ngeoms);
+extern GEOSGeometry GEOS_DLL *GEOSGeom_createEmptyCollection(int type);
extern GEOSGeometry GEOS_DLL *GEOSGeom_createEmptyPolygon_r(
GEOSContextHandle_t handle);
More information about the geos-commits
mailing list