(incubating) | The Free and Open Productivity Suite
Announcing Apache OpenOffice 3.4
OOoRunner test harness

stats
Class InternalLogWriter

java.lang.Object
  |
  +--java.io.Writer
        |
        +--java.io.PrintWriter
              |
              +--stats.InternalLogWriter
All Implemented Interfaces:
LogWriter

public class InternalLogWriter
extends PrintWriter
implements LogWriter

Write all logs into a java.io.PrintWriter, i.e. a StringBuffer. Log is gathered there.


Fields inherited from class java.io.PrintWriter
out
 
Fields inherited from class java.io.Writer
lock
 
Constructor Summary
InternalLogWriter()
          c'*tor
 
Method Summary
 String getLog()
          Return all the written stuff.
 boolean initialize(DescEntry entry, boolean active)
          Initialization.
 void print(String msg)
          Method to print to the StringBuffer.
 void println(String msg)
          Method to print a line that is added to the StringBuffer.
 boolean summary(DescEntry entry)
          Is used to sum up the information.
 
Methods inherited from class java.io.PrintWriter
checkError, close, flush, print, print, print, print, print, print, print, print, println, println, println, println, println, println, println, println, println, setError, write, write, write, write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InternalLogWriter

public InternalLogWriter()
c'*tor
Method Detail

initialize

public boolean initialize(DescEntry entry,
                          boolean active)
Initialization.
Specified by:
initialize in interface LogWriter
Parameters:
entry - The description entry.
active - Logging is active.
Returns:
True, if initialize worked.

println

public void println(String msg)
Method to print a line that is added to the StringBuffer.
Specified by:
println in interface LogWriter
Overrides:
println in class PrintWriter
Parameters:
msg - The message that is printed.

print

public void print(String msg)
Method to print to the StringBuffer.
Overrides:
print in class PrintWriter
Parameters:
msg - The message that is printed.

summary

public boolean summary(DescEntry entry)
Is used to sum up the information. The summary is also added to the StringBuffer.
Specified by:
summary in interface LogWriter
Parameters:
entry - The description entry.
Returns:
True, if a summary could be created.

getLog

public String getLog()
Return all the written stuff.
Returns:
All that was written to the StringBuffer with the 'println()', 'print()' and 'summarize()' methods. The StringBuffer is emptied afterwards.

OOoRunner test harness

Apache Feather

Copyright & License | Privacy | Contact Us

Apache and the Apache feather logos are trademarks of The Apache Software Foundation. OpenOffice.org and the seagull logo are registered trademarks of The Apache Software Foundation. Other names appearing on the site may be trademarks of their respective owners.

Apache OpenOffice is an effort undergoing incubation at The Apache Software Foundation (ASF), sponsored by the Apache Incubator. Incubation is required of all newly accepted projects until a further review indicates that the infrastructure, communications, and decision making process have stabilized in a manner consistent with other successful ASF projects. While incubation status is not necessarily a reflection of the completeness or stability of the code, it does indicate that the project has yet to be fully endorsed by the ASF.