rice.environment.logging.simple
Class SimpleLogManager
java.lang.Object
rice.environment.logging.AbstractLogManager
rice.environment.logging.simple.SimpleLogManager
- All Implemented Interfaces:
- CloneableLogManager, LogManager
- Direct Known Subclasses:
- FileLogManager
public class SimpleLogManager
- extends AbstractLogManager
- implements CloneableLogManager
This class creates loggers that log to a specified PrintStream System.out by default.
- Author:
- Jeff Hoye
Fields inherited from class rice.environment.logging.AbstractLogManager |
dateFormat, dateFormatter, enabled, loggers, nullPrintStream, packageOnly, params, prefix, ps, SYSTEM_ERR, SYSTEM_OUT, time |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
SimpleLogManager
public SimpleLogManager(java.io.PrintStream stream,
TimeSource timeSource,
Parameters params)
- Constructor.
- Parameters:
stream
- the stream to write totimeSource
- the timesource to get times fromminPriority
- the minimum priority to print
SimpleLogManager
public SimpleLogManager(java.io.PrintStream stream,
TimeSource timeSource,
Parameters params,
java.lang.String prefix,
java.lang.String dateFormat)
SimpleLogManager
public SimpleLogManager(Parameters params)
- Convienience constructor.
Defauts to System.out as the stream, and SimpleTimeSource as the timesource.
- Parameters:
minPriority
- the minimum priority to print.
SimpleLogManager
public SimpleLogManager(java.io.PrintStream stream,
Parameters params)
- Convienience constructor.
Defauts to SimpleTimeSource as the timesource.
- Parameters:
stream
- the stream to write tominPriority
- the minimum priority to print
SimpleLogManager
public SimpleLogManager(TimeSource timeSource,
Parameters params)
- Convienience constructor.
Defauts to System.out as the stream.
- Parameters:
timeSource
- the timesource to get times fromminPriority
- the minimum priority to print
getPrintStream
public java.io.PrintStream getPrintStream()
- Overrides:
getPrintStream
in class AbstractLogManager
getParameters
public Parameters getParameters()
getTimeSource
public TimeSource getTimeSource()
- Overrides:
getTimeSource
in class AbstractLogManager
constructLogger
protected Logger constructLogger(java.lang.String clazz,
int level,
boolean useDefault)
- Specified by:
constructLogger
in class AbstractLogManager
clone
public LogManager clone(java.lang.String detail)
- Description copied from interface:
CloneableLogManager
- Return a new LogManager with identical parameters except that
there is an indication of detail in each line, or filename if
seperated by files.
- Specified by:
clone
in interface CloneableLogManager
- Parameters:
detail
- usually will be a nodeid
- Returns:
- a new LogManager
clone
public LogManager clone(java.lang.String detail,
TimeSource ts)
- Specified by:
clone
in interface CloneableLogManager
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
Copyright © 2001-2005 - Rice Pastry.