[XML-SIG] State of the world

Jack Jansen Jack.Jansen@cwi.nl
Wed, 29 Apr 1998 21:56:33 +0200


Recently, Andrew Kuchling <akuchlin@cnri.reston.va.us> said:
> >         * We need to come to some resolution about handling multiple
> > XML documents coming from a single input source. (This is the problem
> > I ran into with xml.marshal, which prevents the code from marshalling
> > two Python objects to the same file and then reading them in again.)
> 
> Actually, this may be problematic. See
> 
> http://www.xml.com/axml/notes/TrailingMisc.html
> 
> for Tim Brays comment on this.
> 
> I think the way around it would be to have every document start with
> an XML declaration. That will make conforming parsers throw an error
> when the new document starts, which can be (maybe with a little 
> extension to the parsers) be caught and used to trigger some code that
> makes the parser consider the rest of the stream a new document.

I think this is all a bad idea. The "xml way" of doing things is to
have a single object per file, and I see no reason why we shouldn't
conform to that. After all, if you need multiple objects you can
easily extend your DTD to allow for this case. Moreover, standard xml
tools will complain bitterly over our files if, say, the xmlpickle DTD 
would describe a single pickled object and you would pass a file with
multiple xmlpickled objects to such a tool.
--
Jack Jansen             | ++++ stop the execution of Mumia Abu-Jamal ++++
Jack.Jansen@cwi.nl      | ++++ if you agree copy these lines to your sig ++++
http://www.cwi.nl/~jack | see http://www.xs4all.nl/~tank/spg-l/sigaction.htm