Class MyExceptionHandler

All Implemented Interfaces:
FacesListener, SystemEventListener, FacesWrapper<ExceptionHandler>, EventListener

public class MyExceptionHandler extends ExceptionHandlerWrapper
Custom JSF ExceptionHandler that intercepts unhandled exceptions and redirects to an appropriate error page.
  • Constructor Details

    • MyExceptionHandler

      public MyExceptionHandler(ExceptionHandler wrapped)
      Creates a new MyExceptionHandler instance.
      Parameters:
      wrapped - a ExceptionHandler object.
  • Method Details

    • handle

      public void handle() throws FacesException
      Overrides:
      handle in class ExceptionHandlerWrapper
      Throws:
      FacesException
    • createRecodLimitExceededMessage

      public String createRecodLimitExceededMessage(Throwable t)
      Parameters:
      t - throwable carrying the RecordLimitExceededException message
      Returns:
      String
    • putNavigationState

      public void putNavigationState(Map<String,Object> requestMap, HttpSession session)
      Parameters:
      requestMap - current JSF request attribute map
      session - current HTTP session for storing navigation state
    • getSessionDetails

      public String getSessionDetails(FacesContext fc)
      Parameters:
      fc - current JSF faces context for accessing the session
      Returns:
      String