| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
  |
  +--java.io.OutputStream
        |
        +--org.apache.tools.ant.taskdefs.LogOutputStream
Logs each line written to this stream to the log system of ant.
 Tries to be smart about line separators.
 TODO: This class can be split to implement other line based processing
 of data written to the stream.
| Constructor Summary | |
| LogOutputStream(ProjectComponent pc,
                int level)Creates a new instance of this class. | |
| LogOutputStream(Task task,
                int level)Creates a new instance of this class. | |
| Method Summary | |
|  void | close()Writes all remaining | 
|  void | flush()Flush this log stream | 
|  int | getMessageLevel() | 
| protected  void | processBuffer()Converts the buffer to a string and sends it to processLine | 
| protected  void | processLine(java.lang.String line)Logs a line to the log system of ant. | 
| protected  void | processLine(java.lang.String line,
            int level)Logs a line to the log system of ant. | 
|  void | write(byte[] b,
      int off,
      int len)Write a block of characters to the output stream | 
|  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 | 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Constructor Detail | 
public LogOutputStream(Task task,
                       int level)
task - the task for whom to loglevel - loglevel used to log data written to this stream.
public LogOutputStream(ProjectComponent pc,
                       int level)
level - loglevel used to log data written to this stream.| Method Detail | 
public void write(int cc)
           throws java.io.IOException
write in class java.io.OutputStreamcc - data to log (byte).
java.io.IOExceptionpublic void flush()
flush in class java.io.OutputStreamprotected void processBuffer()
processLine
protected void processLine(java.lang.String line)
line - the line to log.
protected void processLine(java.lang.String line,
                           int level)
line - the line to log.
public void close()
           throws java.io.IOException
close in class java.io.OutputStreamjava.io.IOExceptionpublic int getMessageLevel()
public void write(byte[] b,
                  int off,
                  int len)
           throws java.io.IOException
write in class java.io.OutputStreamb - the array containing the dataoff - the offset into the array where data startslen - the length of block
java.io.IOException - if the data cannot be written into the stream.| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||