org.mentawai.log
Class SimpleLogger

java.lang.Object
  extended by org.mentawai.log.SimpleLogger
All Implemented Interfaces:
Logger

public class SimpleLogger
extends Object
implements Logger


Constructor Summary
SimpleLogger(File file)
           
SimpleLogger(PrintStream stream)
           
SimpleLogger(PrintWriter out)
           
SimpleLogger(String filename)
           
SimpleLogger(String dir, String filename)
           
 
Method Summary
 void enable(boolean flag)
           
protected  Format getHeaderFormat()
           
protected  Format getRollFileFormat()
           
protected  void header()
           
 void log(Object... objects)
           
 void log(String... msgs)
           
protected  void printTopHeader()
           
 void roll()
           
 void setAlsoSystemOut(boolean flag, String levelString)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleLogger

public SimpleLogger(PrintWriter out)

SimpleLogger

public SimpleLogger(String filename)
             throws IOException
Throws:
IOException

SimpleLogger

public SimpleLogger(String dir,
                    String filename)
             throws IOException
Throws:
IOException

SimpleLogger

public SimpleLogger(File file)
             throws IOException
Throws:
IOException

SimpleLogger

public SimpleLogger(PrintStream stream)
Method Detail

setAlsoSystemOut

public void setAlsoSystemOut(boolean flag,
                             String levelString)

roll

public void roll()
          throws IOException
Specified by:
roll in interface Logger
Throws:
IOException

enable

public void enable(boolean flag)
Specified by:
enable in interface Logger

printTopHeader

protected void printTopHeader()

getRollFileFormat

protected Format getRollFileFormat()

getHeaderFormat

protected Format getHeaderFormat()

header

protected void header()

log

public void log(String... msgs)
Specified by:
log in interface Logger

log

public void log(Object... objects)
Specified by:
log in interface Logger


Copyright © 2012. All Rights Reserved.