LogCapturer (ant-antunit API)
Description: declaration: package: org.apache.ant.antunit, class: LogCapturer

# Klasse LogCapturer

java.lang.Object
org.apache.ant.antunit.LogCapturer

Alle implementierten Schnittstellen:
  `EventListener, org.apache.tools.ant.BuildListener`

public class LogCapturer extends Object implements org.apache.tools.ant.BuildListener
Captures log messages generated during an antunit task run and makes them available to tasks via a project reference.

This class captures all messages generated during the build and adds itself as project reference to the project using the id `ant.antunit.log`.

- ## Feldübersicht

  Felder
  Modifikator und Typ
  Feld
  Beschreibung
  `static final String`
  `REFERENCE_ID`

- ## Konstruktorübersicht

  Konstruktoren
  Konstruktor
  Beschreibung
  `LogCapturer(org.apache.tools.ant.Project p)`

- ## Methodenübersicht

  Modifikator und Typ
  Methode
  Beschreibung
  `void`
  `buildFinished(org.apache.tools.ant.BuildEvent event)`
  De-register.
  `void`
  `buildStarted(org.apache.tools.ant.BuildEvent event)`
  Empty.
  `String`
  `getDebugLog()`
  All messages with `logLevel == Project.MSG_DEBUG` or more severe merging messages into a single line.
  `String`
  `getDebugLog(boolean mergeLines)`
  All messages with `logLevel == Project.MSG_DEBUG` or more severe.
  `String`
  `getErrLog()`
  All messages with `logLevel == Project.MSG_ERR` merging messages into a single line.
  `String`
  `getErrLog(boolean mergeLines)`
  All messages with `logLevel == Project.MSG_ERR`.
  `String`
  `getInfoLog()`
  All messages with `logLevel == Project.MSG_INFO` or more severe merging messages into a single line.
  `String`
  `getInfoLog(boolean mergeLines)`
  All messages with `logLevel == Project.MSG_INFO` or more severe.
  `String`
  `getVerboseLog()`
  All messages with `logLevel == Project.MSG_VERBOSE` or more severe merging messages into a single line.
  `String`
  `getVerboseLog(boolean mergeLines)`
  All messages with `logLevel == Project.MSG_VERBOSE` or more severe.
  `String`
  `getWarnLog()`
  All messages with `logLevel == Project.MSG_WARN` or more severe merging messages into a single line.
  `String`
  `getWarnLog(boolean mergeLines)`
  All messages with `logLevel == Project.MSG_WARN` or more severe.
  `void`
  `messageLogged(org.apache.tools.ant.BuildEvent event)`
  Record the message.
  `void`
  `targetFinished(org.apache.tools.ant.BuildEvent event)`
  Empty.
  `void`
  `targetStarted(org.apache.tools.ant.BuildEvent event)`
  Empty.
  `void`
  `taskFinished(org.apache.tools.ant.BuildEvent event)`
  Empty.
  `void`
  `taskStarted(org.apache.tools.ant.BuildEvent event)`
  Empty.

  ### Von Klasse geerbte Methoden Object

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

- ## Felddetails

  - ### REFERENCE_ID

    public static final String REFERENCE_ID
    Siehe auch:
      - Konstantenfeldwerte

- ## Konstruktordetails

  - ### LogCapturer

    public LogCapturer(org.apache.tools.ant.Project p)

- ## Methodendetails

  - ### getErrLog

    public String getErrLog()
    All messages with `logLevel == Project.MSG_ERR` merging messages into a single line.
    Gibt zurück:
      All messages with `logLevel == Project.MSG_ERR`

  - ### getWarnLog

    public String getWarnLog()
    All messages with `logLevel == Project.MSG_WARN` or more severe merging messages into a single line.
    Gibt zurück:
      All messages with `logLevel == Project.MSG_WARN` or above

  - ### getInfoLog

    public String getInfoLog()
    All messages with `logLevel == Project.MSG_INFO` or more severe merging messages into a single line.
    Gibt zurück:
      All messages with `logLevel == Project.MSG_INFO` or above

  - ### getVerboseLog

    public String getVerboseLog()
    All messages with `logLevel == Project.MSG_VERBOSE` or more severe merging messages into a single line.
    Gibt zurück:
      All messages with `logLevel == Project.MSG_VERBOSE` or above

  - ### getDebugLog

    public String getDebugLog()
    All messages with `logLevel == Project.MSG_DEBUG` or more severe merging messages into a single line.
    Gibt zurück:
      All messages with `logLevel == Project.MSG_DEBUG` or above

  - ### getErrLog

    public String getErrLog(boolean mergeLines)
    All messages with `logLevel == Project.MSG_ERR`.
    Parameter:
      `mergeLines` - whether to merge messages into a single line or split them into multiple lines
    Gibt zurück:
      All messages with `logLevel == Project.MSG_ERR`

  - ### getWarnLog

    public String getWarnLog(boolean mergeLines)
    All messages with `logLevel == Project.MSG_WARN` or more severe.
    Parameter:
      `mergeLines` - whether to merge messages into a single line or split them into multiple lines
    Gibt zurück:
      All messages with `logLevel == Project.MSG_WARN` or above
    Seit:
      AntUnit 1.3

  - ### getInfoLog

    public String getInfoLog(boolean mergeLines)
    All messages with `logLevel == Project.MSG_INFO` or more severe.
    Parameter:
      `mergeLines` - whether to merge messages into a single line or split them into multiple lines
    Gibt zurück:
      All messages with `logLevel == Project.MSG_INFO` or above
    Seit:
      AntUnit 1.3

  - ### getVerboseLog

    public String getVerboseLog(boolean mergeLines)
    All messages with `logLevel == Project.MSG_VERBOSE` or more severe.
    Parameter:
      `mergeLines` - whether to merge messages into a single line or split them into multiple lines
    Gibt zurück:
      All messages with `logLevel == Project.MSG_VERBOSE` or above
    Seit:
      AntUnit 1.3

  - ### getDebugLog

    public String getDebugLog(boolean mergeLines)
    All messages with `logLevel == Project.MSG_DEBUG` or more severe.
    Parameter:
      `mergeLines` - whether to merge messages into a single line or split them into multiple lines
    Gibt zurück:
      All messages with `logLevel == Project.MSG_DEBUG` or above
    Seit:
      AntUnit 1.3

  - ### buildStarted

    public void buildStarted(org.apache.tools.ant.BuildEvent event)
    Empty.
    Angegeben von:
      `buildStarted` in Schnittstelle `org.apache.tools.ant.BuildListener`

  - ### targetStarted

    public void targetStarted(org.apache.tools.ant.BuildEvent event)
    Empty.
    Angegeben von:
      `targetStarted` in Schnittstelle `org.apache.tools.ant.BuildListener`

  - ### targetFinished

    public void targetFinished(org.apache.tools.ant.BuildEvent event)
    Empty.
    Angegeben von:
      `targetFinished` in Schnittstelle `org.apache.tools.ant.BuildListener`

  - ### taskStarted

    public void taskStarted(org.apache.tools.ant.BuildEvent event)
    Empty.
    Angegeben von:
      `taskStarted` in Schnittstelle `org.apache.tools.ant.BuildListener`

  - ### taskFinished

    public void taskFinished(org.apache.tools.ant.BuildEvent event)
    Empty.
    Angegeben von:
      `taskFinished` in Schnittstelle `org.apache.tools.ant.BuildListener`

  - ### buildFinished

    public void buildFinished(org.apache.tools.ant.BuildEvent event)
    De-register.
    Angegeben von:
      `buildFinished` in Schnittstelle `org.apache.tools.ant.BuildListener`

  - ### messageLogged

    public void messageLogged(org.apache.tools.ant.BuildEvent event)
    Record the message.
    Angegeben von:
      `messageLogged` in Schnittstelle `org.apache.tools.ant.BuildListener`