/** * Creates and initializes a BatchInterrupted object. * * @param cause exception that caused batch processing to stop * @param totalCount number of entries parsed so far, note that * it is to be expected that {@code totalCount >= successCount + errorCount} * @param successCount number of entries processed successfully so far * @param errorCount number of entries rejected so far */ public BatchInterrupted(Throwable cause, int totalCount, int successCount, int errorCount) { this(getReasonFromException(cause), totalCount, successCount, errorCount); if (cause instanceof ServiceException) { ServiceException se = (ServiceException)cause; setContent(se.getResponseBody()); setContentType(se.getResponseContentType()); } }
/** * Creates and initializes a BatchInterrupted object. * * @param cause exception that caused batch processing to stop * @param totalCount number of entries parsed so far, note that * it is to be expected that {@code totalCount >= successCount + errorCount} * @param successCount number of entries processed successfully so far * @param errorCount number of entries rejected so far */ public BatchInterrupted(Throwable cause, int totalCount, int successCount, int errorCount) { this(getReasonFromException(cause), totalCount, successCount, errorCount); if (cause instanceof ServiceException) { ServiceException se = (ServiceException)cause; setContent(se.getResponseBody()); setContentType(se.getResponseContentType()); } }
/** * Creates and initializes a BatchInterrupted object. * * @param cause exception that caused batch processing to stop * @param totalCount number of entries parsed so far, note that * it is to be expected that {@code totalCount >= successCount + errorCount} * @param successCount number of entries processed successfully so far * @param errorCount number of entries rejected so far */ public BatchInterrupted(Throwable cause, int totalCount, int successCount, int errorCount) { this(getReasonFromException(cause), totalCount, successCount, errorCount); if (cause instanceof ServiceException) { ServiceException se = (ServiceException)cause; setContent(se.getResponseBody()); setContentType(se.getResponseContentType()); } }