Class AbstractExceptionAwareLogic<R,​C extends WebContext>

    • Field Detail

      • logger

        protected org.slf4j.Logger logger
    • Constructor Detail

      • AbstractExceptionAwareLogic

        public AbstractExceptionAwareLogic()
    • Method Detail

      • handleException

        protected R handleException​(Exception e,
                                    HttpActionAdapter<R,​C> httpActionAdapter,
                                    C context)
        Handle exceptions.
        Parameters:
        e - the thrown exception
        httpActionAdapter - the HTTP action adapter
        context - the web context
        Returns:
        the final HTTP result
      • runtimeException

        protected RuntimeException runtimeException​(Exception exception)
        Wrap an Exception into a RuntimeException.
        Parameters:
        exception - the original exception
        Returns:
        the RuntimeException
      • getErrorUrl

        public String getErrorUrl()
      • setErrorUrl

        public void setErrorUrl​(String errorUrl)
        Define on which error URL the user will be redirected in case of an exception.
        Parameters:
        errorUrl - the error URL