Skip to Content.
Sympa Menu

xom-interest - Re: [XOM-interest] location of elements?

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: Elliotte Harold <elharo AT metalab.unc.edu>
  • To: Michael Kay <mike AT saxonica.com>
  • Cc: xom-interest AT lists.ibiblio.org
  • Subject: Re: [XOM-interest] location of elements?
  • Date: Mon, 30 May 2005 16:50:55 -0400

Michael Kay wrote:

With respect, those are not very good reasons. SAX parsers already provide
the information, and it can be delivered over the API by a single method
getLocation() with a corresponding return class. The implementation of
course is a bit complicated because you have to store the information "out
of band" so there is zero overhead for people who don't need it.


Do any SAX parsers reliably report location information? I haven't noticed one. Most seem to make a reasonable effort to report that information if they can get it without too much trouble. Then again I've only really cared in the tricky case where there's an error. It might be easier to do when the document is well-formed.

--
Elliotte Rusty Harold elharo AT metalab.unc.edu
XML in a Nutshell 3rd Edition Just Published!
http://www.cafeconleche.org/books/xian3/
http://www.amazon.com/exec/obidos/ISBN=0596007647/cafeaulaitA/ref=nosim




Archive powered by MHonArc 2.6.24.

Top of Page