[geos-commits] r2094 - in trunk/source: geom/prep
headers/geos/geom/prep
svn_geos at osgeo.org
svn_geos at osgeo.org
Fri Dec 21 18:12:26 EST 2007
Author: mloskot
Date: 2007-12-21 18:12:26 -0500 (Fri, 21 Dec 2007)
New Revision: 2094
Modified:
trunk/source/geom/prep/AbstractPreparedPolygonContains.cpp
trunk/source/geom/prep/PreparedGeometryFactory.cpp
trunk/source/headers/geos/geom/prep/PreparedGeometryFactory.h
Log:
Fixed extra qualifications in PreparedGeometryFactory class.
Modified: trunk/source/geom/prep/AbstractPreparedPolygonContains.cpp
===================================================================
--- trunk/source/geom/prep/AbstractPreparedPolygonContains.cpp 2007-12-21 22:57:09 UTC (rev 2093)
+++ trunk/source/geom/prep/AbstractPreparedPolygonContains.cpp 2007-12-21 23:12:26 UTC (rev 2094)
@@ -41,8 +41,8 @@
// area around the intersection point, there must exist a situation
// where the interior of the test intersects the exterior of the target.
// This implies the test is NOT contained in the target.
- if ( testGeom->getGeometryTypeId() == GeometryTypeId::GEOS_MULTIPOLYGON
- || testGeom->getGeometryTypeId() == GeometryTypeId::GEOS_POLYGON )
+ if ( testGeom->getGeometryTypeId() == geos::geom::GEOS_MULTIPOLYGON
+ || testGeom->getGeometryTypeId() == geos::geom::GEOS_POLYGON )
return true;
// A single shell with no holes allows concluding that
@@ -165,8 +165,8 @@
// This tests for the case where a ring of the target lies inside
// a test polygon - which implies the exterior of the Target
// intersects the interior of the Test, and hence the result is false
- if ( geom->getGeometryTypeId() == GeometryTypeId::GEOS_MULTIPOLYGON
- || geom->getGeometryTypeId() == GeometryTypeId::GEOS_POLYGON )
+ if ( geom->getGeometryTypeId() == geos::geom::GEOS_MULTIPOLYGON
+ || geom->getGeometryTypeId() == geos::geom::GEOS_POLYGON )
{
// TODO: generalize this to handle GeometryCollections
bool isTargetInTestArea = isAnyTargetComponentInTestArea( geom, prepPoly->getRepresentativePoints());
Modified: trunk/source/geom/prep/PreparedGeometryFactory.cpp
===================================================================
--- trunk/source/geom/prep/PreparedGeometryFactory.cpp 2007-12-21 22:57:09 UTC (rev 2093)
+++ trunk/source/geom/prep/PreparedGeometryFactory.cpp 2007-12-21 23:12:26 UTC (rev 2094)
@@ -36,23 +36,25 @@
const PreparedGeometry *
PreparedGeometryFactory::create( const geom::Geometry * g) const
{
- PreparedGeometry * pg;
+ using geos::geom::GeometryTypeId;
+ PreparedGeometry* pg = 0;
+
switch ( g->getGeometryTypeId() )
{
- case geom::GeometryTypeId::GEOS_MULTIPOINT:
- case geom::GeometryTypeId::GEOS_POINT:
+ case GEOS_MULTIPOINT:
+ case GEOS_POINT:
pg = new PreparedPoint( g);
break;
- case geom::GeometryTypeId::GEOS_LINEARRING:
- case geom::GeometryTypeId::GEOS_LINESTRING:
- case geom::GeometryTypeId::GEOS_MULTILINESTRING:
+ case GEOS_LINEARRING:
+ case GEOS_LINESTRING:
+ case GEOS_MULTILINESTRING:
pg = new PreparedLineString( g);
break;
- case geom::GeometryTypeId::GEOS_POLYGON:
- case geom::GeometryTypeId::GEOS_MULTIPOLYGON:
+ case GEOS_POLYGON:
+ case GEOS_MULTIPOLYGON:
pg = new PreparedPolygon( g);
break;
Modified: trunk/source/headers/geos/geom/prep/PreparedGeometryFactory.h
===================================================================
--- trunk/source/headers/geos/geom/prep/PreparedGeometryFactory.h 2007-12-21 22:57:09 UTC (rev 2093)
+++ trunk/source/headers/geos/geom/prep/PreparedGeometryFactory.h 2007-12-21 23:12:26 UTC (rev 2094)
@@ -72,7 +72,7 @@
* @param geom the geometry to prepare
* @return the prepared geometry
*/
- const PreparedGeometry * PreparedGeometryFactory::create( const geom::Geometry * geom) const;
+ const PreparedGeometry* create( const geom::Geometry* geom) const;
};
} // namespace geos::geom::prep
More information about the geos-commits
mailing list