public class HttpException extends DataNetworkException
An exception thrown if HttpRequest.send cannot be completed due to a network error,
or when one of the HTTP functions is used in an inappropriate manner or with invalid parameters.
| Modifier | Constructor and Description |
|---|---|
|
HttpException()
Default constructor.
|
protected |
HttpException(java.lang.String message,
java.lang.Throwable cause) |
| Modifier and Type | Method and Description |
|---|---|
static HttpException |
withCause(java.lang.RuntimeException cause)
Return a new exception with the specified root cause.
|
static HttpException |
withCauseAndMessage(java.lang.RuntimeException cause,
java.lang.String message)
Return a new exception with the specified root cause and message text.
|
static HttpException |
withMessage(java.lang.String message)
Return a new exception with the specified message text.
|
getSafeMessage, safe, setSafeMessagegetCause, getMessage, setCause, setMessage, toStringprotected HttpException(java.lang.String message,
java.lang.Throwable cause)
public HttpException()
Default constructor.
public static HttpException withCause(java.lang.RuntimeException cause)
Return a new exception with the specified root cause.
cause - Root cause.public static HttpException withCauseAndMessage(java.lang.RuntimeException cause, java.lang.String message)
Return a new exception with the specified root cause and message text.
cause - Root cause.message - Message text.public static HttpException withMessage(java.lang.String message)
Return a new exception with the specified message text.
message - Message text.