Interface ErrorAttributes

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and TypeMethodDescription
      ThrowablegetError​(org.springframework.web.context.request.RequestAttributes requestAttributes)
      Return the underlying cause of the error or null if the error cannot be extracted.
      Map<String,​Object>getErrorAttributes​(org.springframework.web.context.request.RequestAttributes requestAttributes, boolean includeStackTrace)
      Returns a Map of the error attributes.
    • Method Detail

      • getErrorAttributes

        Map<String,​ObjectgetErrorAttributes​(org.springframework.web.context.request.RequestAttributes requestAttributes,
                                                    boolean includeStackTrace)
        Returns a Map of the error attributes. The map can be used as the model of an error page ModelAndView, or returned as a ResponseBody.
        Parameters:
        requestAttributes - the source request attributes
        includeStackTrace - if stack trace elements should be included
        Returns:
        a map of error attributes
      • getError

        Throwable getError​(org.springframework.web.context.request.RequestAttributes requestAttributes)
        Return the underlying cause of the error or null if the error cannot be extracted.
        Parameters:
        requestAttributes - the source request attributes
        Returns:
        the Exception that caused the error or null