nl.knmi.orfeus.seedlink
Class SLLog

java.lang.Object
  extended by nl.knmi.orfeus.seedlink.SLLog

public class SLLog
extends java.lang.Object

Class to manage the logging of informatoin and error messages.


Field Summary
protected  java.io.PrintStream err
          The stream used for output of error messages
protected  java.lang.String errPrefix
          The prefix to prepend to error messages
protected  java.io.PrintStream log
          The stream used for output of informartion messages
protected  java.lang.String logPrefix
          The prefix to prepend to informartion messages
protected  int verbosity
          Verbosity level, 0 is lowest.
 
Constructor Summary
SLLog()
          Creates a new default instance of SLLog.
SLLog(int verbosity, java.io.PrintStream log, java.lang.String logPrefix, java.io.PrintStream err, java.lang.String errPrefix)
          Creates a new instance of SLLog with the specified parameters.
 
Method Summary
 void log(boolean isError, int verbosity, java.lang.String message)
          Logs a message in appropriate manner.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected java.io.PrintStream log
The stream used for output of informartion messages


logPrefix

protected java.lang.String logPrefix
The prefix to prepend to informartion messages


err

protected java.io.PrintStream err
The stream used for output of error messages


errPrefix

protected java.lang.String errPrefix
The prefix to prepend to error messages


verbosity

protected int verbosity
Verbosity level, 0 is lowest.

Constructor Detail

SLLog

public SLLog()
Creates a new default instance of SLLog.


SLLog

public SLLog(int verbosity,
             java.io.PrintStream log,
             java.lang.String logPrefix,
             java.io.PrintStream err,
             java.lang.String errPrefix)
Creates a new instance of SLLog with the specified parameters.

Parameters:
verbosity - verbosity level, 0 is lowest.
log - stream used for output of informartion messages.
logPrefix - prefix to prepend to informartion messages.
err - stream used for output of error messages.
errPrefix - prefix to prepend to error messages.
Method Detail

log

public void log(boolean isError,
                int verbosity,
                java.lang.String message)
Logs a message in appropriate manner.

Parameters:
isError - true if error message, false otherwise.
verbosity - verbosity level for this messages.
message - message text.