[geos-devel] Geometry.isRectangle access difference with JTS
Mateusz Loskot
mateusz at loskot.net
Thu Dec 6 23:28:34 EST 2007
Ben Jubb wrote:
> Fellow GEOSites:
> In my pursuit of porting the lastest and greatest changes from JTS 1.9,
> I've run into a minor issue that I'd like to get some opinions on from
> the earlier porters.
>
> In geom::Geometry, isRectangle() is protected. In JTS (at least for the
> past few versions) this function is public.
> Is there any special reason why the GEOS version is protected?
Ben,
I don't know exact rationale but my understanding is that
isRectangle *was* specific to interface of Polygon class only.
However, existence of default implementation (return false) suggests
that the function is supposed to be available for all geometry types.
>From this point, Geometry::isRectangle as protected is just a design bug.
Cheers
--
Mateusz Loskot
http://mateusz.loskot.net
More information about the geos-devel
mailing list