code: public static <T> T unmarshal(Unmarshaller self, String xml, Class<T> declaredType) throws JAXBException {
          StringReader sr = new StringReader(xml);
          return declaredType.cast(self.unmarshal(sr));
      }
docs: Unmarshal xml data from the given {@code String} to object of the given type.
  
  @param self Unmarshaller, a Unmarshaller which can unmarshall the type of the given object
  @param xml xml data as a {@link String}
  @param declaredType appropriate JAXB mapped class to hold node's xml data
  @return instance of destination class unmarshalled from xml