/** * Creates a BatchStatus and initializes it * based on an exception. * * @param e */ public BatchStatus(ServiceException e) { code = e.getHttpErrorCodeOverride(); if (code == -1) { code = HttpURLConnection.HTTP_INTERNAL_ERROR; } reason = e.getMessage(); contentType = e.getResponseContentType(); content = e.getResponseBody(); }
/** * Creates a BatchStatus and initializes it * based on an exception. * * @param e */ public BatchStatus(ServiceException e) { code = e.getHttpErrorCodeOverride(); if (code == -1) { code = HttpURLConnection.HTTP_INTERNAL_ERROR; } reason = e.getMessage(); contentType = e.getResponseContentType(); content = e.getResponseBody(); }
/** * Creates a BatchStatus and initializes it * based on an exception. * * @param e */ public BatchStatus(ServiceException e) { code = e.getHttpErrorCodeOverride(); if (code == -1) { code = HttpURLConnection.HTTP_INTERNAL_ERROR; } reason = e.getMessage(); contentType = e.getResponseContentType(); content = e.getResponseBody(); }
if (se.getHttpErrorCodeOverride() == HttpURLConnection.HTTP_BAD_GATEWAY) { return new AppsForYourDomainException( AppsForYourDomainErrorCode.ServerBusy, AppsForYourDomainException exception = new AppsForYourDomainException(AppsForYourDomainErrorCode .getEnumFromInt(errorCode), invalidInput, se.getHttpErrorCodeOverride()); return exception;
if (se.getHttpErrorCodeOverride() == HttpURLConnection.HTTP_BAD_GATEWAY) { return new AppsForYourDomainException( AppsForYourDomainErrorCode.ServerBusy, AppsForYourDomainException exception = new AppsForYourDomainException(AppsForYourDomainErrorCode .getEnumFromInt(errorCode), invalidInput, se.getHttpErrorCodeOverride()); return exception;
/** * Creates a BatchStatus and initializes it * based on an exception. * * @param e exception to initialize the status from */ public BatchStatus(ServiceException e) { this(); int code = e.getHttpErrorCodeOverride(); if (code == -1) { code = HttpURLConnection.HTTP_INTERNAL_ERROR; } setCode(code); setReason(e.getMessage()); setContentType(e.getResponseContentType()); setContent(e.getResponseBody()); }
/** * Creates a BatchStatus and initializes it * based on an exception. * * @param e exception to initialize the status from */ public BatchStatus(ServiceException e) { this(); int code = e.getHttpErrorCodeOverride(); if (code == -1) { code = HttpURLConnection.HTTP_INTERNAL_ERROR; } setCode(code); setReason(e.getMessage()); setContentType(e.getResponseContentType()); setContent(e.getResponseBody()); }
/** * Creates a BatchStatus and initializes it * based on an exception. * * @param e exception to initialize the status from */ public BatchStatus(ServiceException e) { this(); int code = e.getHttpErrorCodeOverride(); if (code == -1) { code = HttpURLConnection.HTTP_INTERNAL_ERROR; } setCode(code); setReason(e.getMessage()); setContentType(e.getResponseContentType()); setContent(e.getResponseBody()); }