require()
include REXML
(doc = Document.new) << XMLDecl.new
root = doc.add_element('root')
element = root.add_element('element')
element.add_text('Some text here')



serialized = String.new
doc.write(serialized, 4)
puts serialized