org.momeunit.ant.core
Class OutputLogger

java.lang.Object
  extended by org.momeunit.ant.core.OutputPipe
      extended by org.momeunit.ant.core.OutputLogger
All Implemented Interfaces:
Runnable

public class OutputLogger
extends OutputPipe

Class that reads input from InputStream and logs it to ant logging system. Sends input to pipe if requested.

Version:
1.1.2
Author:
Sergio Morozov

Constructor Summary
OutputLogger(InputStream pipeIn)
          Instantiates OutputLogger with message priority of INFO.
OutputLogger(InputStream pipeIn, org.apache.tools.ant.Task task)
          Instantiates OutputLogger with owning task and message priority of INFO.
OutputLogger(InputStream pipeIn, org.apache.tools.ant.Task task, int msgPriority)
          Instantiates OutputLogger with owning task and message priority.
 
Method Summary
 int getMessagePriority()
          Returns message priority.
 void run()
          Reads input from InputStream and logs it to ant logging system until input is closed.
 void setMessagePriority(int msgPriority)
          Sets message priority.
 void setTask(org.apache.tools.ant.Task task)
          Returns owning task.
 
Methods inherited from class org.momeunit.ant.core.OutputPipe
getInputStream, getOutpuStream, getPipeOutput, setInputStream, start
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OutputLogger

public OutputLogger(InputStream pipeIn,
                    org.apache.tools.ant.Task task,
                    int msgPriority)
Instantiates OutputLogger with owning task and message priority.

Parameters:
pipeIn - InputStream of logger.
task - owning task.
msgPriority - message priority.
Since:
1.1

OutputLogger

public OutputLogger(InputStream pipeIn,
                    org.apache.tools.ant.Task task)
Instantiates OutputLogger with owning task and message priority of INFO.

Parameters:
pipeIn - InputStream of logger.
task - owning task.
Since:
1.1

OutputLogger

public OutputLogger(InputStream pipeIn)
Instantiates OutputLogger with message priority of INFO.

Parameters:
pipeIn - InputStream of logger.
Since:
1.1
Method Detail

getMessagePriority

public int getMessagePriority()
Returns message priority.

Returns:
the message priority.
Since:
1.1

setMessagePriority

public void setMessagePriority(int msgPriority)
Sets message priority.

Parameters:
msgPriority - the message priority to set.
Since:
1.1

setTask

public void setTask(org.apache.tools.ant.Task task)
Returns owning task.

Parameters:
task - the owning task to set.
Since:
1.1

run

public void run()
Reads input from InputStream and logs it to ant logging system until input is closed. Sends input to pipe if requested.

Specified by:
run in interface Runnable
Overrides:
run in class OutputPipe
See Also:
OutputPipe.run()