java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.apache.jena.atlas.web.HttpException
- All Implemented Interfaces:
Serializable
Class of HTTP Exceptions
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionHttpException
(int statusCode) HttpException
(int statusCode, String statusLine) HttpException
(int statusCode, String statusLine, String responseMessage) HttpException
(int statusCode, String statusLine, String responseMessage, Throwable cause) HttpException
(String message) HttpException
(String message, Throwable cause) HttpException
(Throwable cause) -
Method Summary
Modifier and TypeMethodDescriptionThe response payload from the remote.int
Gets the status code, may be -1 if unknownGets the status line text, may be null if unknown.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
HttpException
public HttpException(int statusCode) -
HttpException
-
HttpException
-
HttpException
-
HttpException
-
HttpException
-
HttpException
-
-
Method Details
-
getStatusCode
public int getStatusCode()Gets the status code, may be -1 if unknown- Returns:
- Status Code if known, -1 otherwise
-
getStatusLine
Gets the status line text, may be null if unknown. HTTP/2 does not have status line text; the default HTTP 1.1 message is returned.- Returns:
- Status line
-
getResponse
The response payload from the remote.- Returns:
- The payload, or null if no payload
-