Question

I have two options in front of me for parsing really fat XML file,

  • TouchXML
  • GDataXML

It's lot of work to do because XML file is very huge. I thought of asking people who have already worked with these parsers.

  1. Which one is better for fat XML files?
  2. I found a blog post which says that TouchXML does not edit/save XML files whereas GDataXML has that feature. What exactly do they mean by edit/save XML file feature?
Was it helpful?

Solution

Lets see if I can answer your questions:

  1. Which one is better for fat XML files? The answer is neither. Both are DOM parsers, which actually load the entire document into memory to make queries faster. If you're parsing a large file, you're better off going with a SAX parser, such as the built-in NSXMLParser, or even the SAX-based version of libxml2.
  2. What exactly do they mean by edit/save XML file feature? Well, suppose you have a XML file that has your app's settings in it. If you open up that file and make changes, you're going to want to save them, right? That's where the writing comes in. The parsers that allow writing let you save the representation of the xml file in the memory into an actual file that can be written to disk.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top