tags:

views:

27

answers:

2

What is this for and why might I use it?

A: 

The Simple API for XML (SAX) is one method to process XML documents. Read about SAX at Wikipedia.

It is useful if you have to process really large XML documents.

Felix Kling
+1  A: 

It's for parsing XML in an event based manner. The advantage of SAX is it can handle fairly large xml documents because it's not necessary to load the whole file in memory. But you don't have random access to the elements.

The other way is a DOM based parser, which loads the whole xml file into a dom-tree which you can manipulate.

Ikke