Class GeneralControllerAdviceImpl
java.lang.Object
com.winchesters.devopsify.controller.GeneralControllerAdviceImpl
- All Implemented Interfaces:
GeneralControllerAdvice
- Direct Known Subclasses:
ProjectControllerAdvice
,UserControllerAdvice
@Order
@RestControllerAdvice
public class GeneralControllerAdviceImpl
extends Object
implements GeneralControllerAdvice
-
Field Summary
Fields inherited from interface com.winchesters.devopsify.controller.GeneralControllerAdvice
LOG
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<ErrorResponseDto>
handleBadRequest
(Exception exception) org.springframework.http.ResponseEntity<ErrorResponseDto>
handleException
(Exception exception) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.winchesters.devopsify.controller.GeneralControllerAdvice
handleException
-
Constructor Details
-
GeneralControllerAdviceImpl
public GeneralControllerAdviceImpl()
-
-
Method Details
-
handleException
@ResponseStatus(INTERNAL_SERVER_ERROR) @ExceptionHandler(java.lang.Exception.class) public org.springframework.http.ResponseEntity<ErrorResponseDto> handleException(Exception exception) -
handleBadRequest
@ResponseStatus(BAD_REQUEST) @ExceptionHandler({org.hibernate.exception.ConstraintViolationException.class,org.springframework.http.converter.HttpMessageConversionException.class,javax.validation.ValidationException.class,org.springframework.web.bind.MissingRequestHeaderException.class,com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException.class,org.springframework.validation.BindException.class}) public org.springframework.http.ResponseEntity<ErrorResponseDto> handleBadRequest(Exception exception)
-