code: private Element getXHELMRootElement(String resource) throws JDOMException, IOException {
  
  		ByteArrayInputStream stream = new ByteArrayInputStream(resource.getBytes());
  		SAXBuilder builder = new SAXBuilder();
  		Document doc = builder.build(stream);
  
  		return doc.getRootElement();
  	}
docs: method to get the XHELMRootElement of a document as a string
  
  @param resource
  xhelm input
  @return XHELMRootElement
  @throws JDOMException
  if the xml can not be read
  @throws IOException
  if the input can not be read