Package thredds.server
Class TdsErrorHandling
- java.lang.Object
-
- thredds.server.TdsErrorHandling
-
- All Implemented Interfaces:
org.springframework.web.servlet.HandlerExceptionResolver
@Configuration @ControllerAdvice public class TdsErrorHandling extends Object implements org.springframework.web.servlet.HandlerExceptionResolver
Global Exception handling ServiceNotAllowed FORBIDDEN FileNotFoundException NOT_FOUND IOException INTERNAL_SERVER_ERROR UnsupportedOperationException BAD_REQUEST IllegalArgumentException BAD_REQUEST BindException BAD_REQUEST Throwable INTERNAL_SERVER_ERROR- Since:
- 4/15/2015
- See Also:
- "https://spring.io/blog/2013/11/01/exception-handling-in-spring-mvc"
-
-
Constructor Summary
Constructors Constructor Description TdsErrorHandling()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.http.ResponseEntity<String>handle(FileNotFoundException ex)org.springframework.http.ResponseEntity<String>handle(IOException ex)org.springframework.http.ResponseEntity<String>handle(IllegalArgumentException ex)org.springframework.http.ResponseEntity<String>handle(Throwable ex)org.springframework.http.ResponseEntity<String>handle(org.springframework.validation.BindException ex)org.springframework.http.ResponseEntity<String>handle(org.springframework.web.bind.ServletRequestBindingException ex)org.springframework.http.ResponseEntity<String>handle(MethodNotImplementedException ex)org.springframework.http.ResponseEntity<String>handle(RequestTooLargeException ex)org.springframework.http.ResponseEntity<String>handle(ServiceNotAllowed ex)org.springframework.http.ResponseEntity<String>handle(NcssException ex)org.springframework.web.servlet.ModelAndViewresolveException(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, Object handler, Exception ex)
-
-
-
Method Detail
-
handle
@ExceptionHandler(ServiceNotAllowed.class) public org.springframework.http.ResponseEntity<String> handle(ServiceNotAllowed ex)
-
handle
@ExceptionHandler(RequestTooLargeException.class) public org.springframework.http.ResponseEntity<String> handle(RequestTooLargeException ex)
-
handle
@ExceptionHandler(MethodNotImplementedException.class) public org.springframework.http.ResponseEntity<String> handle(MethodNotImplementedException ex)
-
handle
@ExceptionHandler(java.io.FileNotFoundException.class) public org.springframework.http.ResponseEntity<String> handle(FileNotFoundException ex)
-
handle
@ExceptionHandler(java.io.IOException.class) public org.springframework.http.ResponseEntity<String> handle(IOException ex)
-
handle
@ExceptionHandler(java.lang.IllegalArgumentException.class) public org.springframework.http.ResponseEntity<String> handle(IllegalArgumentException ex)
-
handle
@ExceptionHandler(NcssException.class) public org.springframework.http.ResponseEntity<String> handle(NcssException ex)
-
handle
@ExceptionHandler(org.springframework.web.bind.ServletRequestBindingException.class) public org.springframework.http.ResponseEntity<String> handle(org.springframework.web.bind.ServletRequestBindingException ex)
-
handle
@ExceptionHandler(org.springframework.validation.BindException.class) public org.springframework.http.ResponseEntity<String> handle(org.springframework.validation.BindException ex)
-
handle
@ExceptionHandler(java.lang.Throwable.class) public org.springframework.http.ResponseEntity<String> handle(Throwable ex) throws Throwable
- Throws:
Throwable
-
resolveException
public org.springframework.web.servlet.ModelAndView resolveException(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, Object handler, Exception ex)- Specified by:
resolveExceptionin interfaceorg.springframework.web.servlet.HandlerExceptionResolver
-
-