creof / doctrine2-spatial

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

Introducing a general support for native JSON serialization. #194

Open bucefal91 opened 6 years ago

bucefal91 commented 6 years ago

Here's a rather simple patch that allows spatial data to be json-serialized through native PHP toolset. I am far from being 100% sure this patch covers all use cases, but it does mine (Symfony FOS rest bundle with a JSON content type).

coveralls commented 6 years ago

Coverage Status

Coverage decreased (-17.9%) to 80.119% when pulling 7013441ca73cd1324bb639ea86b82f50287344a2 on bucefal91:140-json-serializable into 58ea5fae1c1b450ee08d7dac25cd9e8f5e6fdebd on creof:master.

Alexandre-T commented 4 years ago

This request #209 which implements JsonSerializable. You could have a look at this fork. Deployed on packagist, a new package is now available for PHP7.2+