private <T>String elementToString(JAXBElement<T> element) throws Exception {
  StringWriter writer=new StringWriter();
  marshaller.marshal(element,writer);
  return writer.toString();
}

private < T > String elementToString ( JAXBElement < T > element ) throws Exception { StringWriter writer = new StringWriter ( ) ; marshaller . marshal ( element , writer ) ; return writer . toString ( ) ; }
serializes the given xml element to a string .
