Package de.pangaea.metadataportal.utils

## Class LoggingErrorListener

- java.lang.Object
- - de.pangaea.metadataportal.utils.LoggingErrorListener

- All Implemented Interfaces:
    `ErrorListener`

      public final class LoggingErrorListener
      extends Object
      implements ErrorListener

  Helper class to correctly log `TransformerException`s with Commons Logging.
  Author:
    Uwe Schindler

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `LoggingErrorListener​(Class<?> c)` | A error listener using the supplied class name as log target.
    `LoggingErrorListener​(org.apache.commons.logging.Log log)` | A error listener using the supplied Commons Logging instance as log target.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `error​(TransformerException e)` | Just throws `e`.
    `void` | `fatalError​(TransformerException e)` | Just throws `e`.
    `void` | `warning​(TransformerException e)` | Logs message and location with WARN method.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### LoggingErrorListener

          public LoggingErrorListener​(org.apache.commons.logging.Log log)

      A error listener using the supplied Commons Logging instance as log target.

    - #### LoggingErrorListener

          public LoggingErrorListener​(Class<?> c)

      A error listener using the supplied class name as log target.

  - ### Method Detail

    - #### error

          public void error​(TransformerException e)
                     throws TransformerException

      Just throws `e`.
      Specified by:
        `error` in interface `ErrorListener`
      Throws:
        `TransformerException`

    - #### fatalError

          public void fatalError​(TransformerException e)
                          throws TransformerException

      Just throws `e`.
      Specified by:
        `fatalError` in interface `ErrorListener`
      Throws:
        `TransformerException`

    - #### warning

          public void warning​(TransformerException e)
                       throws TransformerException

      Logs message and location with WARN method.
      Specified by:
        `warning` in interface `ErrorListener`
      Throws:
        `TransformerException`