cds.util
Class DebugLog

java.lang.Object
  extended byjava.util.logging.Logger
      extended bycds.util.DebugLog

public class DebugLog
extends java.util.logging.Logger

Debugger log

Version:
1.0 Jan 2004
Author:
Marc Wenger/CDS

Field Summary
private static java.util.logging.Level DEFAULT_LEVEL
           
private static DebugFormat df
           
private  java.util.logging.Level lev
           
private  java.util.logging.Logger log
           
private static java.util.logging.LogManager logman
           
private  java.util.logging.Logger toplog
           
 
Fields inherited from class java.util.logging.Logger
global
 
Constructor Summary
DebugLog(java.lang.String name)
          Constructor
 
Method Summary
static DebugLog getLog(java.lang.String name)
           
 void setConsole(boolean doit)
          Specifies the Console (stderr) output
 void setFile(java.lang.String filename, boolean append)
          Set a file output
 void setLevel(java.util.logging.Level lev)
          Set the logging level
 
Methods inherited from class java.util.logging.Logger
addHandler, config, entering, entering, entering, exiting, exiting, fine, finer, finest, getAnonymousLogger, getAnonymousLogger, getFilter, getHandlers, getLevel, getLogger, getLogger, getName, getParent, getResourceBundle, getResourceBundleName, getUseParentHandlers, info, isLoggable, log, log, log, log, log, logp, logp, logp, logp, logrb, logrb, logrb, logrb, removeHandler, setFilter, setParent, setUseParentHandlers, severe, throwing, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_LEVEL

private static java.util.logging.Level DEFAULT_LEVEL

log

private java.util.logging.Logger log

toplog

private java.util.logging.Logger toplog

lev

private java.util.logging.Level lev

logman

private static java.util.logging.LogManager logman

df

private static final DebugFormat df
Constructor Detail

DebugLog

public DebugLog(java.lang.String name)
Constructor

Parameters:
name - Name of the Logger. It can be found anywhere by
LogManager.getLogManager().getLogger(name)
Method Detail

getLog

public static DebugLog getLog(java.lang.String name)

setLevel

public void setLevel(java.util.logging.Level lev)
Set the logging level

Parameters:
lev - logging level (from Level.SEVERE to Level.FINEST)

setFile

public void setFile(java.lang.String filename,
                    boolean append)
Set a file output

Parameters:
filename - name of the file
append - true if the output should be appended to the file

setConsole

public void setConsole(boolean doit)
Specifies the Console (stderr) output

Parameters:
doit - true if the output should also be redirected to stderr. This is independant of a file output