Groovy StAX builder

by Dejan Bosanac

I've always loved Groovy builders concept for handling (mostly creating) hierarchical documents. On the other hand I find StAX, pull-based processing API, to be one of my favorite methods for dealing with simple XML processing. It's simple and fast, so what more can I ask for? Additionally, thanks to the Jettison project you can also use the StAX API to handle JSON documents. So, basically we can use one simple (standard) API to handle both XML and JSON documents in the same manner. The next logical step is to merge these two great pieces of technology into one.