StAX (JSR 173)
By manishkg on Apr 26, 2007
A very nice introduction of Streaming API for XML is provided in this article. In summary, we can understand StAX by compairing it with SAX :
SAX (Simple API for XML) : Push API (observer design pattern... Parser feed the content of the document to the application as soon as they see it). Only reading of document is allowed.
StAX (Streaming API for XML) : Pull API (iterator design pattern... Client program asks the parser for the next piece of information ). Both read and write are possible.
There are many similarities in these 2 APIs -
Ease of Use, CPU and memory efficient, Forward only and No XPath capability.
Java Web Service tutorial is an excellent document to learn more about StAX.