Class ErrorHandlerFactory

java.lang.Object
org.apache.jena.riot.system.ErrorHandlerFactory

public class ErrorHandlerFactory extends Object
  • Field Details

    • stdLogger

      public static final org.slf4j.Logger stdLogger
    • noLogger

      public static final org.slf4j.Logger noLogger
    • errorHandlerStd

      public static final ErrorHandler errorHandlerStd
      Standard error handler - logs to stdLogger
    • errorHandlerNoWarnings

      public static final ErrorHandler errorHandlerNoWarnings
      Error handler (no warnings) - logs to stdLogger
    • errorHandlerStrict

      public static final ErrorHandler errorHandlerStrict
      Strict error handler - logs to stdLogger - exceptions for warnings
    • errorHandlerWarn

      public static final ErrorHandler errorHandlerWarn
      Warning error handler - logs to stdLogger - messages for warnings and some errors
    • errorHandlerNoLogging

      public static final ErrorHandler errorHandlerNoLogging
      Silent error handler : ignores warnings, throws exceptions for errors
    • errorHandlerStrictNoLogging

      public static final ErrorHandler errorHandlerStrictNoLogging
      Silent, strict error handler
  • Constructor Details

    • ErrorHandlerFactory

      public ErrorHandlerFactory()
  • Method Details

    • errorHandlerStrictSilent

      public static ErrorHandler errorHandlerStrictSilent()
      Silent, strict error handler, no logging
    • errorHandlerStrict

      public static ErrorHandler errorHandlerStrict(org.slf4j.Logger log)
      Strict error handler, with logging
    • errorHandlerStd

      public static ErrorHandler errorHandlerStd(org.slf4j.Logger log)
      An error handler that logs messages, then throws exceptions for errors but not warnings
    • errorHandlerIgnoreWarnings

      public static ErrorHandler errorHandlerIgnoreWarnings(org.slf4j.Logger log)
      An error handler that logs error and fatal messages, but not warnings
    • errorHandlerWarning

      public static ErrorHandler errorHandlerWarning(org.slf4j.Logger log)
      An error handler that logs messages for errors and warnings and attempts to carry on
    • errorHandlerSimple

      public static ErrorHandler errorHandlerSimple()
      Ignores warnings, throws exceptions for errors
    • errorHandlerExceptionOnError

      public static ErrorHandler errorHandlerExceptionOnError()
      An error handler that throws a RiotParseException, hence it exposes the details of errors.
    • errorHandlerExceptions

      public static ErrorHandler errorHandlerExceptions()
      An error handler that throws exceptions in all cases.
    • errorHandlerWarnOrExceptions

      public static ErrorHandler errorHandlerWarnOrExceptions(org.slf4j.Logger logger)
      An error handler that logs warnings and throws exceptions on error and fatal.
    • getDefaultErrorHandler

      public static ErrorHandler getDefaultErrorHandler()
      Get the current default error handler
    • setDefaultErrorHandler

      public static void setDefaultErrorHandler(ErrorHandler errorHandler)
      Set the current default error handler - use carefully, mainly for use in testing