module MultiXml::Parsers::Rexml

def parse(xml)

XML Document IO to parse
xml::

Parse an XML Document IO into a simple hash using REXML
def parse(xml)
  doc = REXML::Document.new(xml)
  raise(REXML::ParseException, "The document #{doc.to_s.inspect} does not have a valid root") unless doc.root
  merge_element!({}, doc.root)
end