URL url = apiUrl.buildUrl();
String webpage = requestWebPage(url);
try {
WrapperMovieList wrapper = mapper.readValue(webpage, WrapperMovieList.class);
TmdbResultsList<MovieList> results = new TmdbResultsList<MovieList>(wrapper.getMovieList());
results.copyWrapper(wrapper);
return results;
} catch (IOException ex) {
LOG.warn("Failed to get movie lists: {}", ex.getMessage(), ex);
throw new MovieDbException(MovieDbExceptionType.MAPPING_FAILED, webpage, url, ex);