When is it appropriate to use SAX and when is it appropriate to use the DOM?
SAX uses an event driven model to notify the application of document elements as it's reading the document. This makes it more suitable if memory is a concern, or for large documents, because any content your application doesn't care about can be immediately discarded without consuming memory. Because it is event driven, it can be more difficult to set up the appropriate callback routines, etc. than to use the DOM.