String responseBody = responseHandler.handleResponse(response);
T object = (T) unmarshaller
.unmarshal(new StringReader(responseBody));
return object;
} catch (ClientProtocolException ex) {
throw new RestException(ex);
} catch (IOException ex) {
throw new RestException(ex);
} catch (JAXBException ex) {
throw new RestException(ex);
}
}