This week's book giveaway is in the General Computing forum. We're giving away four copies of Arduino in Action and have Martin Evans, Joshua Noble, and Jordan Hochenbaum on-line! See this thread for details.
But if you can't see how, I would suggest you convert a start-element event to a string containing a representation of an element's start tag, and so on. You won't necessarily get an exact representation of what's there, for example you may get attributes in a different order and you may represent empty elements differently, but that's allowed by the rules of XML.