[OpenLayers-Trac] [OpenLayers] #3022: GeoJSON format output
produces invalid CRS
OpenLayers
trac-20090302 at openlayers.org
Thu Jan 20 12:32:17 EST 2011
#3022: GeoJSON format output produces invalid CRS
----------------------------+-----------------------------------------------
Reporter: hoxworth | Owner: hoxworth@…
Type: bug | Status: new
Priority: minor | Milestone: 2.11 Release
Component: Format.GeoJSON | Version: SVN
Keywords: geojson | State:
----------------------------+-----------------------------------------------
'''Description''': The GeoJSON format writer creates a coordinate
reference system object that does not conform to the GeoJSON
[http://geojson.org/geojson-spec.html#coordinate-reference-system-objects
spec].
'''Reproduction''': Call 'OpenLayers.Format.GeoJSON().write(feature)' on
any feature.
'''Location''':
[source:/trunk/openlayers/lib/OpenLayers/Format/GeoJSON.js#L494 Source]
'''Expected''': A GeoJSON object should be created with a 'crs' property
that conforms to the GeoJSON [http://geojson.org/geojson-spec.html
#coordinate-reference-system-objects spec]. An example follows:
{{{
"crs": {
"type" : "name",
"properties" : {
"name" : "urn:ogc:def:crs:OGC:1.3:CRS84"
}
}
}}}
'''Actual Experience''': A GeoJSON object is created with a 'crs' property
of the following format:
{{{
"crs" : {
"type" : "OGC",
"properties" : {
"urn" : "urn:ogc:def:crs:OGC:1.3:CRS84"
}
}
}}}
'''Impact''': Minimal. This bug affects all browsers/runtimes, but only
impacts users who depend on GeoJSON output for connection with external
systems.
'''Solution''': Patch is attached.
--
Ticket URL: <http://trac.openlayers.org/ticket/3022>
OpenLayers <http://openlayers.org/>
A free AJAX map viewer
More information about the Trac
mailing list