} catch (ReportException e) {
System.out.println("\n(Error: " + e.getMessage() + " " + e.getCause() + " Retry# " + i
+ "/" + retriesCount + ")");
} catch (ReportDownloadResponseException e) {
if (e instanceof DetailedReportDownloadResponseException) {
DetailedReportDownloadResponseException detailedException =
(DetailedReportDownloadResponseException) e;
System.out.println("\n(Error: " + detailedException.getType() + " Trigger:"
+ detailedException.getTrigger() + ")");
// Not retrying DetailedReportDownloadResponseException errors.
break;
} else {
System.out.println("\n(Error: " + e.getMessage() + " " + e.getCause() + " Retry# " + i
+ "/" + retriesCount + ")");