creof / doctrine2-spatial

Doctrine2 multi-platform support for spatial types and functions.
MIT License
272 stars 174 forks source link

Geography polygon allows invalid coordinates #130

Open svycka opened 8 years ago

svycka commented 8 years ago

for example geography point does not allow incorrect coordinates. example:

POINT(10000 10000)

would throw CrEOF\Spatial\Exception\InvalidValueException with message:

Invalid longitude value "10000", must be in range -180 to 180.

but in geography polygon case it allows 10000 as coordinate. example polygon:

POLYGON((10000 55.168750449796,1000 1000,10000 55.168750449796))

this should be valid geometry polygon, but not a geography polygon otherwise what's the point of geography polygon?

djlambert commented 8 years ago

Yes that should also throw an exception.