Class RestException
java.lang.Object
java.lang.Throwable
java.lang.Exception
com.github.damianwajser.exceptions.RestException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
BadRequestException,ConflictException,ForbiddenException,LockedException,MethodNotAllowedException,NotAcceptableException,NotFoundException,PaymentRequiredException,PreconditionFailedException,UnprocessableEntityException,UnsupportedMediaTypeException
public abstract class RestException extends Exception
- See Also:
- Serialized Form
-
Field Summary
Fields Modifier and Type Field Description protected List<ExceptionDetail>details -
Constructor Summary
Constructors Constructor Description RestException(ExceptionDetail detail)RestException(ExceptionDetail detail, Exception e)RestException(String errorCode, String errorMessage, Optional<Object> errorDetail)RestException(String errorCode, String errorMessage, Optional<Object> errorDetail, Exception e)RestException(List<ExceptionDetail> details)RestException(List<ExceptionDetail> details, Exception e) -
Method Summary
Modifier and Type Method Description List<ExceptionDetail>getDetails()ErrorMessagegetErrorMessage(javax.servlet.http.HttpServletRequest request)org.springframework.http.HttpStatusgetHttpCode()Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Field Details
-
Constructor Details
-
Method Details
-
getDetails
-
getErrorMessage
-
getHttpCode
public org.springframework.http.HttpStatus getHttpCode()
-