/** * Generates a new {@link ErrorHandler} which creates a <tt>HandledException</tt> without actually logging or * processing it. * <p> * This can be used to generate a <tt>HandledException</tt> based on a user error (invalid input) * which doesn't need to be logged. * * @return a new <tt>ErrorHandler</tt> to handle an error or exception */ public static ErrorHandler createHandled() { return new ErrorHandler(false); }
/** * Generates a new {@link ErrorHandler} which gracefully handles all kinds of errors * * @return a new <tt>ErrorHandler</tt> to handle an error or exception */ public static ErrorHandler handle() { return new ErrorHandler(true); }