× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



dmosley@xxxxxxxxxx wrote:
...
So, what I did instead was for every "*XML_START_ELEMENT" event, I would take the <tag> name
and execute an XML-INTO to get the tag's value.
So, in that sense, avoiding all other events, just made sense.

It's doing what I want it to do, I was just hoping to make it a bit more efficient.


David, it's not going to be at all efficient if you are using XML-INTO to reparse the XML document every time your XML-SAX finds a new element. Rather than having the one XML-SAX loop, you have your XML-SAX loop plus a number of hidden XML-INTO loops.

XML-INTO has to parse the XML document starting at the beginning to find the bit that it's interested in. XML-INTO does stop when it has found what it's looking for but on average you will be parsing half the document for each XML-INTO that looks for the value of a specific tag.

I have to repeat Scott's question: Why not just use XML-INTO for the entire XML document? Then you will only parse the XML document once and when XML-INTO is done, you will have all the information you need.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.