Trying to get an Entity from a REST service. My code is like this:
I want to send in an object like this: new GenericType<List<MyObject>>() {}
to a methode like this:
public static Object callRestWithUrl(String url, Class<?> responseObject)
throws MetaServiceException {
ClientResponse response = RESTConnectionUtils.callMetaService(url);
result = response.getEntity(responseObject);
.....
But it gets evaluated to List during runtime and not GenericType and an exception is thrown.