OpenLayers OpenLayers

Ticket #1366 (new feature)

Opened 1 year ago

Last modified 2 weeks ago

Atom Format

Reported by: seang Assigned to: tschaub
Priority: critical Milestone: 2.9 Release
Component: Format Version: SVN
Keywords: atom georss gml Cc:
State: Review

Description (Last modified by tschaub)

Add an atom format for generating atom feed docs from features or atom entry docs from a single feature. Use georss:where to describe geometries. This will make use of the versioned GML parser (using v3 - which will conform with the simple features profile).

Attachments

atom.patch (20.8 kB) - added by tschaub on 09/12/08 10:27:35.
adds an atom format
format-atom.patch (36.9 kB) - added by sgillies on 06/03/09 16:51:11.

Change History

02/18/08 03:27:54 changed by crschmidt

  • milestone set to 2.7 Release.

Please make the GMLSF a subclass, probably named GML.SimpleFeatures (instead of GMLSF), subclassing from Format.GML instead of from Format.XML, and let me know when it's done, and I'll look at it.

(Hopefully, you only have to override one or two functions: It wasn't clear to me what actually changed, so I can't be sure yet.)

04/18/08 09:42:15 changed by tschaub

Working on this now (see Atom.js). I'd like to use this new style for XML parsers (see SLD). I'll add the versioning bit later. The idea is to be able to more easily extend custom functionality to parsers (by creating custom writers and readers functions) and to be able to share parsing code between formats (filter, sld, gml, etc). Also, this style parser visits each node once at most - too much getElementsByTagNameNS will sink us. Requires a handful of additions to XML.js.

07/28/08 16:17:56 changed by crschmidt

  • priority changed from minor to critical.

08/26/08 08:08:40 changed by euzuro

  • state set to Needs More Work.

09/05/08 15:20:50 changed by euzuro

  • version changed from 2.5 to 2.7 RC1.

Floating to RC1... vector-behavior patches will go in on RC2.

09/05/08 18:18:38 changed by tschaub

Not ready for review yet, just placing this here in case my machine gets hit by a bus over lunch.

The addition of the Atom format comes with a couple changes to the xml format. These will be of use (and will reduce code duplication) in the other (new style) parsers. I've put together tests for the XML changes. Tests for Atom to come (GML changes will be handled in #1639).

09/05/08 22:49:59 changed by tschaub

  • description changed.
  • summary changed from Atom and GML Simple Features Formats to Atom Format.

09/05/08 23:08:27 changed by tschaub

The updated patch only contains atom specific changes now. Required changes to the xml format are attached to #1722. This still produces gml with the parser in the trunk (gml 2 largely - so not in conformance with the simple features profile). So, this is still waiting for #1639.

09/12/08 10:27:35 changed by tschaub

  • attachment atom.patch added.

adds an atom format

09/12/08 10:37:28 changed by tschaub

This depends on #1639. This also does not yet conform with http://www.ietf.org/rfc/rfc4287.txt, so I'm leaving this "needs work." Not much, but I can't finish it now.

09/12/08 15:28:23 changed by euzuro

  • milestone changed from 2.7 Release to 2.8 Release.

03/02/09 02:21:13 changed by crschmidt

Seems like this is pretty close, perhaps we want to actually pull it into 2.8?

03/18/09 15:36:19 changed by crschmidt

  • milestone changed from 2.8 Release to 2.9 Release.

No love, bumping to 2.9.

06/03/09 04:49:11 changed by sgillies

  • version changed from 2.7 RC1 to SVN.

For 2.9, I've attached a new OpenLayers.Format.Atom class and tests (all passing). It implements pretty much all of RFC 4287 except atom:source. Parsed Atom metadata goes into an "atom" namespace in feature attributes (feature.attributes.atom). atom:title and atom:summary are also copied to feature.attributes.title and feature.attributes.description.

The class uses the GML.v3 format to write out geometries and read children of georss:where elements. GeoRSS simple elements are read using code adapted from the GeoRSS format. It doesn't use the new XML parsing framework (readers and writers), but doesn't need to right now since there's not much to share with other formats.

06/03/09 16:51:11 changed by sgillies

  • attachment format-atom.patch added.

06/23/09 20:03:18 changed by sgillies

  • state changed from Needs More Work to Review.

Review and commit, please.