[geos-commits] [SCM] GEOS branch main updated. 79f75266db60f5c69f5ae48ebc8680b2b26c9f01

git at osgeo.org git at osgeo.org
Wed Sep 29 14:21:27 PDT 2021


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GEOS".

The branch, main has been updated
       via  79f75266db60f5c69f5ae48ebc8680b2b26c9f01 (commit)
      from  90fc07bf2363e02e1bc5f2d1979447dc00479f58 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 79f75266db60f5c69f5ae48ebc8680b2b26c9f01
Author: Sandro Santilli <strk at kbt.io>
Date:   Wed Sep 29 23:17:38 2021 +0200

    isDistanceWithin -> isWithinDistance, for consistency with Geometry
    
    Also try to fix Doxygen (blindly, as cmake doesn't recognize I do
    have Doxygen installed).

diff --git a/capi/geos_c.h.in b/capi/geos_c.h.in
index 0d2ac4a..50a19bb 100644
--- a/capi/geos_c.h.in
+++ b/capi/geos_c.h.in
@@ -3321,9 +3321,9 @@ extern int GEOS_DLL GEOSPreparedDistance(
 * Useful for situations where
 * one geometry is large and static and needs to be tested
 * against a large number of other geometries.
-* \param[in] pg1 The prepared geometry
-* \param[in] g2 The geometry to test
-* \param[in] dist The max distance
+* \param pg1 The prepared geometry
+* \param g2 The geometry to test
+* \param dist The max distance
 * \return 1 on success
 */
 extern char GEOS_DLL GEOSPreparedDistanceWithin(
@@ -3989,9 +3989,9 @@ extern int GEOS_DLL GEOSDistance(
 /**
 * Test whether the distance between two geometries is
 * within the given dist.
-* \param[in] g1 Input geometry
-* \param[in] g2 Input geometry
-* \param[in] dist max distance
+* \param g1 Input geometry
+* \param g2 Input geometry
+* \param dist The max distance
 * \returns 1 on true, 0 on false, 2 on exception
 */
 extern char GEOS_DLL GEOSDistanceWithin(
diff --git a/capi/geos_ts_c.cpp b/capi/geos_ts_c.cpp
index 3abc02b..cfb4c0e 100644
--- a/capi/geos_ts_c.cpp
+++ b/capi/geos_ts_c.cpp
@@ -3287,7 +3287,7 @@ extern "C" {
                          const Geometry* g, double dist)
     {
         return execute(extHandle, 2, [&]() {
-            return pg->isDistanceWithin(g, dist);
+            return pg->isWithinDistance(g, dist);
         });
     }
 
diff --git a/include/geos/geom/prep/BasicPreparedGeometry.h b/include/geos/geom/prep/BasicPreparedGeometry.h
index 714d2f5..9898ca4 100644
--- a/include/geos/geom/prep/BasicPreparedGeometry.h
+++ b/include/geos/geom/prep/BasicPreparedGeometry.h
@@ -184,7 +184,7 @@ public:
     /**
      * Default implementation.
      */
-    bool isDistanceWithin(const geom::Geometry* geom, double dist) const override;
+    bool isWithinDistance(const geom::Geometry* geom, double dist) const override;
 
     std::string toString();
 
diff --git a/include/geos/geom/prep/PreparedGeometry.h b/include/geos/geom/prep/PreparedGeometry.h
index eda52ad..0e5ec44 100644
--- a/include/geos/geom/prep/PreparedGeometry.h
+++ b/include/geos/geom/prep/PreparedGeometry.h
@@ -222,11 +222,12 @@ public:
      * distance from the given geometry.
      *
      * @param geom the Geometry to test the distance to
+     * @param dist the distance value to compare
      * @return true if this Geometry is within the given distance from
      * the given Geometry.
      *
      */
-    virtual bool isDistanceWithin(const geom::Geometry* geom, double dist) const = 0;
+    virtual bool isWithinDistance(const geom::Geometry* geom, double dist) const = 0;
 };
 
 
diff --git a/src/geom/prep/BasicPreparedGeometry.cpp b/src/geom/prep/BasicPreparedGeometry.cpp
index a3e058a..27b4537 100644
--- a/src/geom/prep/BasicPreparedGeometry.cpp
+++ b/src/geom/prep/BasicPreparedGeometry.cpp
@@ -172,7 +172,7 @@ BasicPreparedGeometry::distance(const geom::Geometry* g) const
 }
 
 bool
-BasicPreparedGeometry::isDistanceWithin(const geom::Geometry* g, double dist) const
+BasicPreparedGeometry::isWithinDistance(const geom::Geometry* g, double dist) const
 {
     return baseGeom->isWithinDistance(g, dist);
 }

-----------------------------------------------------------------------

Summary of changes:
 capi/geos_c.h.in                               | 12 ++++++------
 capi/geos_ts_c.cpp                             |  2 +-
 include/geos/geom/prep/BasicPreparedGeometry.h |  2 +-
 include/geos/geom/prep/PreparedGeometry.h      |  3 ++-
 src/geom/prep/BasicPreparedGeometry.cpp        |  2 +-
 5 files changed, 11 insertions(+), 10 deletions(-)


hooks/post-receive
-- 
GEOS


More information about the geos-commits mailing list