new JSONObject(response.getContentAsString())));
// call the provider as though the wink-client was in use on the client side
InputStream is = new ByteArrayInputStream(response.getContentAsByteArray());
JacksonJsonProvider jacksonProvider = new JacksonJsonProvider();
Animal animal = (Animal)jacksonProvider.readFrom(Object.class, Animal.class, null, MediaType.APPLICATION_JSON_TYPE, null, is);
// make sure pseudo polymorphism support works. See Animal class with @JsonCreator and @JsonProperty annotations
assertEquals(Dog.class, animal.getClass());
}