RE: [xml-dev] RFC for XML Object Parsing

From
Brian Aberle <>
To
Norman Gray <>, "" <>
Date
2014-03-24T22:44:53Z
ID
<>
Thread
RE: [xml-dev] RFC for XML Object Parsing
Norman
 
So it's official some SAX parsers can do this and some cannot.  It depends on the implementation.  That's the final word.
 
In the case of the _large_ XML file there is no choice, it's this or something that's not XML.  The additional uses cases of automatic support for element updates is handier than you know.  Once you live with it for a while you cant live without it - like a smart phone.  Many programmers write code to handle updates.  I hope you can take the time to run two examples, ExIndexObjects, and TheOIDProtocol in the source download here: http://1drv.ms/1jjcJub
 
You will see more use cases for the more typical situation via OID updates in those two examples.
 
Brian
 

 
> Subject: Re: [xml-dev] RFC for XML Object Parsing
> From: [email protected]
> Date: Mon, 24 Mar 2014 21:19:24 +0000
> CC: [email protected]; [email protected]
> To: [email protected]
>
>
> Brian, hello.
>
> On 2014 Mar 24, at 20:52, Brian Aberle <[email protected]> wrote:
>
> > SAX should be calling all your handlers in the order that they appear in the XML,
>
> No: as Amy said, the SAX interface specification does not require the elements in the Attributes interface to appear in any particular order. If one particular parser (implementation) finds it convenient to report them in reverse order, for whatever reason, then it's allowed to do that.
>
> If you have a particular parser which happens to report attributes in document order; and if that XML is (known to be) generated in such a way that the @oid attribute value will be unchanged if the element content is unchanged; and if that parser implementation is such that you can thereupon quickly skip to the end of that element; then yes: you have a situation which will rather neatly optimise the reading of a _large_ XML file.
>
> But you will surely agree that that is a rather unusual situation, and thus that there will be rather few situations in which this optimisation will be useful.
>
> Best wishes,
>
> Norman
>
>
> --
> Norman Gray : http://nxg.me.uk
> SUPA School of Physics and Astronomy, University of Glasgow, UK
>