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