Class ErrorHandlerAdapter

  • All Implemented Interfaces:
    ErrorHandler

    public class ErrorHandlerAdapter
    extends Object
    implements ErrorHandler
    Makes a Log4j 1 ErrorHandler usable by a Log4j 2 Appender.
    • Constructor Detail

      • ErrorHandlerAdapter

        public ErrorHandlerAdapter​(ErrorHandler errorHandler)
    • Method Detail

      • error

        public void error​(String msg)
        Description copied from interface: ErrorHandler
        Handle an error with a message.
        Specified by:
        error in interface ErrorHandler
        Parameters:
        msg - The message.
      • error

        public void error​(String msg,
                          Throwable t)
        Description copied from interface: ErrorHandler
        Handle an error with a message and an exception.
        Specified by:
        error in interface ErrorHandler
        Parameters:
        msg - The message.
        t - The Throwable.
      • error

        public void error​(String msg,
                          LogEvent event,
                          Throwable t)
        Description copied from interface: ErrorHandler
        Handle an error with a message, and exception and a logging event.
        Specified by:
        error in interface ErrorHandler
        Parameters:
        msg - The message.
        event - The LogEvent.
        t - The Throwable.