org.apache.tools.ant
Class DemuxOutputStream
java.lang.Object
|
+--java.io.OutputStream
|
+--org.apache.tools.ant.DemuxOutputStream
- public class DemuxOutputStream
- extends java.io.OutputStream
Logs content written by a thread and forwards the buffers onto the
project object which will forward the content to the appropriate
task
- Author:
- Conor MacNeill
Method Summary |
void |
close()
Writes all remaining |
void |
flush()
Writes all remaining |
protected void |
processBuffer()
Converts the buffer to a string and sends it to processLine |
void |
write(int cc)
Write the data to the buffer and flush the buffer, if a line
separator is detected. |
Methods inherited from class java.io.OutputStream |
write, write |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DemuxOutputStream
public DemuxOutputStream(Project project,
boolean isErrorStream)
- Creates a new instance of this class.
- Parameters:
task
- the task for whom to loglevel
- loglevel used to log data written to this stream.
write
public void write(int cc)
throws java.io.IOException
- Write the data to the buffer and flush the buffer, if a line
separator is detected.
- Overrides:
write
in class java.io.OutputStream
- Parameters:
cc
- data to log (byte).
processBuffer
protected void processBuffer()
- Converts the buffer to a string and sends it to
processLine
close
public void close()
throws java.io.IOException
- Writes all remaining
- Overrides:
close
in class java.io.OutputStream
flush
public void flush()
throws java.io.IOException
- Writes all remaining
- Overrides:
flush
in class java.io.OutputStream
Copyright © 1999-2001 Apache Software Foundation. All Rights Reserved.