Package sk.gursky.films.rest
Class UsersAdvice
java.lang.Object
sk.gursky.films.rest.UsersAdvice
@ControllerAdvice
public class UsersAdvice
extends java.lang.Object
-
Constructor Summary
Constructors Constructor Description UsersAdvice()
-
Method Summary
Modifier and Type Method Description ApiError
handleDaoException(DaoException e)
ApiError
handleForbiddenActionException(ForbiddenActionException e)
ApiError
handleNullPointerException(java.lang.NullPointerException e)
ApiError
handleUnauthorizedActionException(UnauthorizedActionException e)
-
Constructor Details
-
UsersAdvice
public UsersAdvice()
-
-
Method Details
-
handleDaoException
@ExceptionHandler(DaoException.class) @ResponseStatus(NOT_ACCEPTABLE) @ResponseBody public ApiError handleDaoException(DaoException e) -
handleNullPointerException
@ExceptionHandler(java.lang.NullPointerException.class) @ResponseStatus(BAD_REQUEST) @ResponseBody public ApiError handleNullPointerException(java.lang.NullPointerException e) -
handleUnauthorizedActionException
@ExceptionHandler(UnauthorizedActionException.class) @ResponseStatus(UNAUTHORIZED) @ResponseBody public ApiError handleUnauthorizedActionException(UnauthorizedActionException e) -
handleForbiddenActionException
@ExceptionHandler(ForbiddenActionException.class) @ResponseStatus(FORBIDDEN) @ResponseBody public ApiError handleForbiddenActionException(ForbiddenActionException e)
-