Issue Type: Bug Bug
Affects Versions: 8.0-RC2, 8.0-RC1
Assignee: Unassigned
Attachments: GeoJsonTest.java
Components: geojson
Created: 02/Aug/12 9:56 AM
Description:

GeoJSON does not parse GeometryCollection items - here's my test output:

Testing geom: POINT (4 6)

SimpleFeatureImpl:FEATURE_RECORD=[SimpleFeatureImpl.Attribute: geometry<geometry id=fid-7205cfc1_138e7ce8900_-8000>=POINT (4 6), SimpleFeatureImpl.Attribute: name<name id=fid-7205cfc1_138e7ce8900_-8000>=Name 123, SimpleFeatureImpl.Attribute: label<label id=fid-7205cfc1_138e7ce8900_-8000>=Label 321, SimpleFeatureImpl.Attribute: roles<roles id=fid-7205cfc1_138e7ce8900_-8000>=[1, 2, 3]]

{"type":"Feature","geometry":{"type":"Point","coordinates":[4,6]},"properties":{"name":"Name 123","label":"Label 321","roles":"[1, 2, 3]"},"id":"fid-7205cfc1_138e7ce8900_-8000"}

SimpleFeatureImpl:FEATURE_RECORD=[SimpleFeatureImpl.Attribute: geometry<geometry id=fid-7205cfc1_138e7ce8900_-8000>=POINT (4 6), SimpleFeatureImpl.Attribute: name<name id=fid-7205cfc1_138e7ce8900_-8000>=Name 123, SimpleFeatureImpl.Attribute: label<label id=fid-7205cfc1_138e7ce8900_-8000>=Label 321, SimpleFeatureImpl.Attribute: roles<roles id=fid-7205cfc1_138e7ce8900_-8000>=[1, 2, 3]]

Testing geom: LINESTRING (4 6, 7 10)

SimpleFeatureImpl:FEATURE_RECORD=[SimpleFeatureImpl.Attribute: geometry<geometry id=fid-7205cfc1_138e7ce8900_-7fff>=LINESTRING (4 6, 7 10), SimpleFeatureImpl.Attribute: name<name id=fid-7205cfc1_138e7ce8900_-7fff>=Name 123, SimpleFeatureImpl.Attribute: label<label id=fid-7205cfc1_138e7ce8900_-7fff>=Label 321, SimpleFeatureImpl.Attribute: roles<roles id=fid-7205cfc1_138e7ce8900_-7fff>=[1, 2, 3]]

{"type":"Feature","geometry":{"type":"LineString","coordinates":[[4,6],[7,10]]},"properties":{"name":"Name 123","label":"Label 321","roles":"[1, 2, 3]"},"id":"fid-7205cfc1_138e7ce8900_-7fff"}

SimpleFeatureImpl:FEATURE_RECORD=[SimpleFeatureImpl.Attribute: geometry<geometry id=fid-7205cfc1_138e7ce8900_-7fff>=LINESTRING (4 6, 7 10), SimpleFeatureImpl.Attribute: name<name id=fid-7205cfc1_138e7ce8900_-7fff>=Name 123, SimpleFeatureImpl.Attribute: label<label id=fid-7205cfc1_138e7ce8900_-7fff>=Label 321, SimpleFeatureImpl.Attribute: roles<roles id=fid-7205cfc1_138e7ce8900_-7fff>=[1, 2, 3]]

Testing geom: GEOMETRYCOLLECTION (POINT (4 6), LINESTRING (4 6, 7 10))

SimpleFeatureImpl:FEATURE_RECORD=[SimpleFeatureImpl.Attribute: geometry<geometry id=fid-7205cfc1_138e7ce8900_-7ffe>=GEOMETRYCOLLECTION (POINT (4 6), LINESTRING (4 6, 7 10)), SimpleFeatureImpl.Attribute: name<name id=fid-7205cfc1_138e7ce8900_-7ffe>=Name 123, SimpleFeatureImpl.Attribute: label<label id=fid-7205cfc1_138e7ce8900_-7ffe>=Label 321, SimpleFeatureImpl.Attribute: roles<roles id=fid-7205cfc1_138e7ce8900_-7ffe>=[1, 2, 3]]

{"type":"Feature","geometry":{"type":"GeometryCollection","geometries":[{"type":"Point","coordinates":[4,6]},{"type":"LineString","coordinates":[[4,6],[7,10]]}]},"properties":{"name":"Name 123","label":"Label 321","roles":"[1, 2, 3]"},"id":"fid-7205cfc1_138e7ce8900_-7ffe"}

SimpleFeatureImpl:FEATURE_RECORD=[SimpleFeatureImpl.Attribute: geometry<geometry id=fid-5291b192_138e7d58270_-7ffe>=null, SimpleFeatureImpl.Attribute: name<name id=fid5291b192_138e7d58270_-7ffe>=Name 123, SimpleFeatureImpl.Attribute: label<label id=fid5291b192_138e7d58270_-7ffe>=Label 321, SimpleFeatureImpl.Attribute: roles<roles id=fid-5291b192_138e7d58270_-7ffe>=[1, 2, 3]]

Environment: Java 1.7, Windows 7 x64
Project: GeoTools
Priority: Major Major
Reporter: Mark Paxton
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
GeoTools-Devel mailing list
GeoTools-Devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to