Package com.maxmind.minfraud.exception
Class HttpException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.io.IOException
-
- com.maxmind.minfraud.exception.HttpException
-
- All Implemented Interfaces:
Serializable
public final class HttpException extends IOException
This class represents an HTTP transport error. This is not an error returned by the web service itself. As such, it is a IOException instead of a MinFraudException.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description HttpException(String message, int httpStatus, URL url)
HttpException(String message, int httpStatus, URL url, Throwable cause)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getHttpStatus()
URL
getUrl()
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
HttpException
public HttpException(String message, int httpStatus, URL url)
- Parameters:
message
- A message describing the reason why the exception was thrown.httpStatus
- The HTTP status of the response that caused the exception.url
- The URL queried.
-
HttpException
public HttpException(String message, int httpStatus, URL url, Throwable cause)
- Parameters:
message
- A message describing the reason why the exception was thrown.httpStatus
- The HTTP status of the response that caused the exception.url
- The URL queried.cause
- The cause of the exception.
-
-
Method Detail
-
getHttpStatus
public int getHttpStatus()
- Returns:
- the HTTP status of the query that caused the exception.
-
getUrl
public URL getUrl()
- Returns:
- the URL queried.
-
-