// and in English, and I cannot think of another way to
// distinguish this error, which we must distinguish.
if ("Premature end-of-data on socket".equals(e.getMessage())) {
return new RepositoryDocumentException(e);
} else {
return new LivelinkIOException(e, LOGGER);
}
} else if (e instanceof LLBadServerCertificateException
|| e instanceof LLCouldNotConnectException
|| e instanceof LLCouldNotConnectHTTPException
|| e instanceof LLHTTPAccessDeniedException
|| e instanceof LLHTTPCGINotFoundException
|| e instanceof LLHTTPClientException
|| e instanceof LLHTTPForbiddenException
|| e instanceof LLHTTPProxyAuthRequiredException
|| e instanceof LLHTTPRedirectionException
|| e instanceof LLHTTPServerException
|| e instanceof LLSSLNotAvailableException
|| e instanceof LLSecurityProviderException
|| e instanceof LLUnsupportedAuthMethodException
|| e instanceof LLWebAuthInitException) {
return new LivelinkIOException(e, LOGGER);
} else {
return new LivelinkException(e, LOGGER);
}
}