peterstace / simplefeatures

Simple Features is a pure Go Implementation of the OpenGIS Simple Feature Access Specification
MIT License
125 stars 19 forks source link

Bugfix: check geometry collection coordinate types #613

Closed peterstace closed 2 months ago

peterstace commented 2 months ago

Description

Fixes a bug where geometry collection coordinate types were allowed to mismatch. E.g. GEOMETRYCOLLECTION M(POINT Z(1 2 0)) is not allowed because the collection is marked as M but the point is marked as Z.

An extension beyond the OGC standard is implemented, allowing untagged geometry collections to contain any coordinate types, so long as they are all the same. So GEOMETRYCOLLECTION(POINT M(1 2 0), POINT M(2 3 0)) is allowed, but GEOMETRYCOLLECTION(POINT Z(1 2 0), POINT M(2 3 4)) is not.

Check List

Have you:

Related Issue

peterstace commented 2 months ago

Thanks for reviewing!