Class ErrorHandler

  • All Implemented Interfaces:
    Handler<RoutingContext>

    public class ErrorHandler
    extends Object
    implements Handler<RoutingContext>
    A pretty error handler for rendering error pages. When working in development mode exception details will be returned in the server responses, otherwise or when manually specified no exception details are returned in the HTTP response. The reason the display of the exception details is by default dependent of the mode is to follow the security best practices: https://www.owasp.org/index.php/Improper_Error_Handling

    NOTE: This class has been automatically generated from the original non RX-ified interface using Vert.x codegen.

    • Constructor Detail

      • ErrorHandler

        public ErrorHandler​(ErrorHandler delegate)
      • ErrorHandler

        public ErrorHandler​(Object delegate)
    • Method Detail

      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • create

        public static ErrorHandler create​(Vertx vertx)
        Create an error handler using defaults
        Parameters:
        vertx -
        Returns:
        the handler
      • create

        public static ErrorHandler create​(Vertx vertx,
                                          String errorTemplateName,
                                          boolean displayExceptionDetails)
        Create an error handler
        Parameters:
        vertx -
        errorTemplateName - the error template name - will be looked up from the classpath
        displayExceptionDetails - true if exception details should be displayed
        Returns:
        the handler
      • create

        public static ErrorHandler create​(Vertx vertx,
                                          boolean displayExceptionDetails)
        Create an error handler
        Parameters:
        vertx -
        displayExceptionDetails - true if exception details should be displayed
        Returns:
        the handler
      • create

        public static ErrorHandler create​(Vertx vertx,
                                          String errorTemplateName)
        Create an error handler
        Parameters:
        vertx -
        errorTemplateName - the error template name - will be looked up from the classpath
        Returns:
        the handler