Class RestException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
javax.ws.rs.ProcessingException
javax.ws.rs.client.ResponseProcessingException
com.peterphi.std.guice.restclient.exception.RestException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
AuthenticationFailureException
,UnboundRestException
public class RestException
extends javax.ws.rs.client.ResponseProcessingException
- See Also:
-
Constructor Summary
ConstructorDescriptionRestException
(int httpCode, String msg) RestException
(int httpCode, String msg, Throwable cause) RestException
(String msg, Throwable cause) -
Method Summary
Modifier and TypeMethodDescriptionlong
int
javax.ws.rs.client.ClientResponseContext
boolean
protected void
setErrorCode
(long code) protected void
setHttpCode
(int httpCode) void
setResponseContext
(javax.ws.rs.client.ClientResponseContext responseContext) Methods inherited from class javax.ws.rs.client.ResponseProcessingException
getResponse
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
RestException
-
RestException
-
RestException
-
-
Method Details
-
setErrorCode
protected void setErrorCode(long code) -
setHttpCode
protected void setHttpCode(int httpCode) -
getErrorCode
public long getErrorCode() -
getHttpCode
public int getHttpCode() -
getFailure
-
isCausedByRemote
public boolean isCausedByRemote() -
setResponseContext
public void setResponseContext(javax.ws.rs.client.ClientResponseContext responseContext) -
getResponseContext
public javax.ws.rs.client.ClientResponseContext getResponseContext()
-