Added attributes support in XML Recorder.

The XML recorder will now add node attributes to the generated XML string.