/** * Gets an exception reader for the exception * * @param t the exception to get a reader for * @return either a specific reader or an instance of DefaultExceptionReader. This method never * returns null; */ public static ExceptionReader getExceptionReader(Throwable t) { for (ExceptionReader exceptionReader : exceptionReaders) { if (exceptionReader.getExceptionType().isInstance(t)) { return exceptionReader; } } return defaultExceptionReader; }