public class RestException
extends java.lang.Exception
Exception,
Serialized Form| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
CLASS_VERSION
Class version string
|
| Constructor and Description |
|---|
RestException(java.util.List<java.lang.Throwable> pCauses,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
A constructor which takes a List of source exceptions, response object and error code.
|
RestException(java.lang.String pMessage,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
A constructor which takes a message, response object and error code.
|
RestException(java.lang.String pMessage,
java.util.List<java.lang.Throwable> pCauses,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
A constructor which takes a message, a List of source exceptions, response object and error code.
|
RestException(java.lang.String pMessage,
java.lang.Throwable pCause,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
A constructor which takes a source exception, response object and error code.
|
RestException(java.lang.Throwable pCause,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
A constructor which takes a source exception, response object and error code.
|
| Modifier and Type | Method and Description |
|---|---|
java.util.List<java.lang.Throwable> |
getCauses()
Returns a List of exceptions which caused the RestException
|
int |
getErrorCode()
Returns the error code that was set into the response object for this exception.
|
void |
setCauses(java.util.List<java.lang.Throwable> pCauses)
Sets the causes property.
|
void |
setErrorCode(int pErrorCode)
Sets the error code that was set into the response object for this exception
|
public RestException(java.lang.String pMessage,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
pMessage - an error message describing the REST exception.pResponse - the servlet response objectpErrorCode - an error code to set into the response object. This should be one of the error codes
defined in javax.servlet.http.HttpServletResponse.HttpServletResponsepublic RestException(java.lang.Throwable pCause,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
pCause - the source exceptionpResponse - the servlet response objectpErrorCode - an error code to set into the response object. This should be one of the error codes
defined in javax.servlet.http.HttpServletResponse.HttpServletResponsepublic RestException(java.lang.String pMessage,
java.lang.Throwable pCause,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
pMessage - an error message describing the REST exception.pCause - the source exceptionpResponse - the servlet response objectpErrorCode - an error code to set into the response object. This should be one of the error codes
defined in javax.servlet.http.HttpServletResponse.HttpServletResponsepublic RestException(java.util.List<java.lang.Throwable> pCauses,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
pCauses - a List of source exceptionspResponse - the servlet response objectpErrorCode - an error code to set into the response object. This should be one of the error codes
defined in javax.servlet.http.HttpServletResponse.HttpServletResponsepublic RestException(java.lang.String pMessage,
java.util.List<java.lang.Throwable> pCauses,
javax.servlet.http.HttpServletResponse pResponse,
int pErrorCode)
pMessage - an error message describing the REST exception.pCauses - a List of source exceptionspResponse - the servlet response objectpErrorCode - an error code to set into the response object. This should be one of the error codes
defined in javax.servlet.http.HttpServletResponse.HttpServletResponsepublic int getErrorCode()
public void setErrorCode(int pErrorCode)
pErrorCode - the error code that was set into the response object for this exceptionpublic java.util.List<java.lang.Throwable> getCauses()
public void setCauses(java.util.List<java.lang.Throwable> pCauses)
pCauses - the causes to set