MediaType m, MultivaluedMap<String, String> headers, InputStream is) {
try {
JAXBContext context = getJAXBContext(type);
Unmarshaller unmarshaller = context.createUnmarshaller();
BadgerFishXMLInputFactory factory = new BadgerFishXMLInputFactory();
XMLStreamReader xsw = factory.createXMLStreamReader(is);
Object obj = unmarshaller.unmarshal(xsw);
xsw.close();
return obj;
} catch (JAXBException e) {
e.printStackTrace();