org.schmant.support.io
Class PrintProcessOutputStrategy

java.lang.Object
  extended by org.schmant.support.io.PrintProcessOutputStrategy
All Implemented Interfaces:
ProcessOutputStrategy

public class PrintProcessOutputStrategy
extends Object
implements ProcessOutputStrategy

This ProcessOutputStrategy prints its output to a PrintWriter, for instance System.out or System.err.

Since:
0.8
Author:
Karl Gustafsson

Constructor Summary
PrintProcessOutputStrategy(PrintWriter out)
          Create a new process output strategy.
 
Method Summary
 ProcessOutputListener getOutputListener()
          Create a new process output listener for listening to a process.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PrintProcessOutputStrategy

public PrintProcessOutputStrategy(PrintWriter out)
Create a new process output strategy.

Parameters:
out - The writer to write the process' output to. This can for instance be System.out or System.err.
Method Detail

getOutputListener

public ProcessOutputListener getOutputListener()
Description copied from interface: ProcessOutputStrategy
Create a new process output listener for listening to a process.

Specified by:
getOutputListener in interface ProcessOutputStrategy
Returns:
A new process output listener.