i am having all my database data in the form of an XML message (A string ) .This is dynamically being constructed using Xstream API . (So XML construction is not a Problem )
This String will be about early about 80 lines .
Now i need to parse this XML file and read the values in it .
Now should i use SAX or DOM API to do this ??
(As i read that there are somewhat performance issues with each approach ) .
I tried to change the world, but I couldn’t find the source code
If you are considering DOM and SAx, you might also want to check out VTD-XML (http://vtd-xml.sf.net), which has
several distinct advantages of DOM and SAX, such as performance, memory usage and native XPath support etc..
This will entirely depend on what you will be doing with the parsed xml. If you are just going to read some values from the xml document, SAX should be enough. But if you also want to edit the xml, then you need to have a DOM parser.