public void warning(TransformerException e) throws TransformerException { logger.warn(e.getMessageAndLocation()); throw e; }
public void fatalError(TransformerException e) throws TransformerException { logger.warn(e.getMessageAndLocation()); throw e; }
public void error(TransformerException e) throws TransformerException { logger.warn(e.getMessageAndLocation()); throw e; }
public void warning(TransformerException e) throws TransformerException { logger.warn(e.getMessageAndLocation()); throw e; }
public void error(TransformerException e) throws TransformerException { logger.warn(e.getMessageAndLocation()); throw e; }
public void fatalError(TransformerException e) throws TransformerException { logger.warn(e.getMessageAndLocation()); throw e; }
/** * Log a fatal error. * @param e the exception to log. */ public void fatalError(final TransformerException e) { logError(e, "Fatal Error"); throw new BuildException("Fatal error during transformation using " + stylesheet + ": " + e.getMessageAndLocation(), e); }
/** * Receive notification of a warning. * Transformers can use this method to report conditions that are not * errors or fatal errors. The default behaviour is to take no action. * After invoking this method, the Transformer must continue with the * transformation. It should still be possible for the application to * process the document through to the end. * * @param e The warning information encapsulated in a transformer * exception. * @throws TransformerException if the application chooses to discontinue * the transformation (never does in our case). */ public void warning(TransformerException e) throws TransformerException { Throwable wrapped = e.getException(); if (wrapped != null) { System.err.println(new ErrorMsg(ErrorMsg.WARNING_PLUS_WRAPPED_MSG, e.getMessageAndLocation(), wrapped.getMessage())); } else { System.err.println(new ErrorMsg(ErrorMsg.WARNING_MSG, e.getMessageAndLocation())); } }
/** * Receive notification of a recoverable error. * The transformer must continue to provide normal parsing events after * invoking this method. It should still be possible for the application * to process the document through to the end. * * @param e The warning information encapsulated in a transformer * exception. * @throws TransformerException if the application chooses to discontinue * the transformation (always does in our case). */ public void error(TransformerException e) throws TransformerException { Throwable wrapped = e.getException(); if (wrapped != null) { System.err.println(new ErrorMsg(ErrorMsg.ERROR_PLUS_WRAPPED_MSG, e.getMessageAndLocation(), wrapped.getMessage())); } else { System.err.println(new ErrorMsg(ErrorMsg.ERROR_MSG, e.getMessageAndLocation())); } throw e; }
/** * Receive notification of a non-recoverable error. * The application must assume that the transformation cannot continue * after the Transformer has invoked this method, and should continue * (if at all) only to collect addition error messages. In fact, * Transformers are free to stop reporting events once this method has * been invoked. * * @param e warning information encapsulated in a transformer * exception. * @throws TransformerException if the application chooses to discontinue * the transformation (always does in our case). */ public void fatalError(TransformerException e) throws TransformerException { Throwable wrapped = e.getException(); if (wrapped != null) { System.err.println(new ErrorMsg(ErrorMsg.FATAL_ERR_PLUS_WRAPPED_MSG, e.getMessageAndLocation(), wrapped.getMessage())); } else { System.err.println(new ErrorMsg(ErrorMsg.FATAL_ERR_MSG, e.getMessageAndLocation())); } throw e; }
/** * Receive notification of a non-recoverable error. * The application must assume that the transformation cannot continue * after the Transformer has invoked this method, and should continue * (if at all) only to collect addition error messages. In fact, * Transformers are free to stop reporting events once this method has * been invoked. * * @param e The warning information encapsulated in a transformer * exception. * @throws TransformerException if the application chooses to discontinue * the transformation (always does in our case). */ public void fatalError(TransformerException e) throws TransformerException { Throwable wrapped = e.getException(); if (wrapped != null) { System.err.println(new ErrorMsg(ErrorMsg.FATAL_ERR_PLUS_WRAPPED_MSG, e.getMessageAndLocation(), wrapped.getMessage())); } else { System.err.println(new ErrorMsg(ErrorMsg.FATAL_ERR_MSG, e.getMessageAndLocation())); } throw e; }
/** * Receive notification of a recoverable error. * The transformer must continue to provide normal parsing events after * invoking this method. It should still be possible for the application * to process the document through to the end. * * @param e The warning information encapsulated in a transformer * exception. * @throws TransformerException if the application chooses to discontinue * the transformation (always does in our case). */ public void error(TransformerException e) throws TransformerException { Throwable wrapped = e.getException(); if (wrapped != null) { System.err.println(new ErrorMsg(ErrorMsg.ERROR_PLUS_WRAPPED_MSG, e.getMessageAndLocation(), wrapped.getMessage())); } else { System.err.println(new ErrorMsg(ErrorMsg.ERROR_MSG, e.getMessageAndLocation())); } throw e; }
/** * Receive notification of a warning. * Transformers can use this method to report conditions that are not * errors or fatal errors. The default behaviour is to take no action. * After invoking this method, the Transformer must continue with the * transformation. It should still be possible for the application to * process the document through to the end. * * @param e The warning information encapsulated in a transformer * exception. * @throws TransformerException if the application chooses to discontinue * the transformation (never does in our case). */ public void warning(TransformerException e) throws TransformerException { Throwable wrapped = e.getException(); if (wrapped != null) { System.err.println(new ErrorMsg(ErrorMsg.WARNING_PLUS_WRAPPED_MSG, e.getMessageAndLocation(), wrapped.getMessage())); } else { System.err.println(new ErrorMsg(ErrorMsg.WARNING_MSG, e.getMessageAndLocation())); } }
throw new DOMException(DOMException.NAMESPACE_ERR,e.getMessageAndLocation()); else throw new XPathException(XPathException.INVALID_EXPRESSION_ERR,e.getMessageAndLocation());
} catch (TransformerException te) { throw new XPathException(XPathException.INVALID_EXPRESSION_ERR,te.getMessageAndLocation());
public void warning(TransformerException e) throws TransformerException { LOG.warn("Warning: " + e.getMessageAndLocation(), e); } }
public void error(final TransformerException te) throws TransformerException { log.debug("error " + te.getMessageAndLocation()); errors.add(te); }
public void warning(final TransformerException te) throws TransformerException { log.debug("warning " + te.getMessageAndLocation()); errors.add(te); } };
@Override public void warning(final TransformerException warning) { Logger.warn( this, "#warning(): %s", warning.getMessageAndLocation() ); this.errors.add(warning.getMessageAndLocation()); }
/** * @see ErrorListener#error(TransformerException) * * @param exception An error reported by the transformer. * * @throws TransformerException If thrown by the underlying {@link ErrorCollector}. */ @Override public void error(TransformerException exception) throws TransformerException { this._logger.error(exception.getMessageAndLocation()); collect(Level.ERROR, exception); }