xml in fptools?

Graham Klyne GK at ninebynine.org
Fri May 26 13:43:28 EDT 2006


S. Alexander Jacobson wrote:
> Can we talk about Haskell use cases?  It seems like we want different
> APIs for parsing, transforming, and producing XML.

My use case was this:

To parse XML from some internal or external source (resolving internal and maybe
external entities), yielding a structure that was recognizable like the XML
infoset, which I then used to write an XMl->RDF parser based closely on the RDF
syntax specification (which is defined in terms of the infoset).

Which suggests, in response to Malcolm, that an internal representation might
usefully be based on the XML infoset specification.  A number of web standards
define XML -based languages in terms of the infoset, so that irrelevant
difference in the character-level syntax don't get in the way (e.g. <x></x> vs
<x/>).

Also, as I write, I'm on my way back from WWW2006, where there has been much
talk of "microformats" and RDFa, both of which layer machine readable data on
top ox XML syntax as a way of merging HTML with "semantic" content.  For these
cases, I think that access to the XML data model is needed.  In summary, I think
there are significant numbers of cases where what we are trying to get at is not
the XML structure represented as Haskell data types, but something encoded using
XML structures, those being what one might want to yield a Haskell data type.
So I'd be wary of saying that we don't want access to the XML structure per se.

#g

-- 
Graham Klyne
For email:
http://www.ninebynine.org/#Contact



More information about the Libraries mailing list