|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.labs.minion.util.MinionLog
@Deprecated public class MinionLog
A general purpose logging facility for the indexing and query engine. There are three kinds of messages that can be logged:
log
method.
warn method.error
methoddebug
methodYou can also specify a logging level, and only messages whose level is lower than that level will be printed.
| Field Summary | |
|---|---|
static int |
DEBUG
Deprecated. Static constant for debug messages. |
static int |
ERROR
Deprecated. Static constant for error messages. |
protected static MinionLog |
instance
Deprecated. The static instance for our Singleton. |
static int |
LOG
Deprecated. Static constant for log messages. |
protected static int[] |
logLevels
Deprecated. The logging levels. |
static java.lang.String |
PROP_LOG_FILE
Deprecated. The property name for the log file. |
protected static java.io.OutputStream[] |
streams
Deprecated. The output streams. |
static int |
WARN
Deprecated. Static constant for warning messages. |
protected static java.io.PrintWriter[] |
writers
Deprecated. The PrintWriters associated with the streams. |
| Constructor Summary | |
|---|---|
MinionLog()
Deprecated. Protected constructor for the singleton log. |
|
| Method Summary | |
|---|---|
static void |
debug(java.lang.String module,
int level,
java.lang.String msg)
Deprecated. Logs a debug message. |
static void |
debug(java.lang.String module,
int level,
java.lang.String msg,
java.lang.Throwable t)
Deprecated. Logs a debug message. |
static void |
error(java.lang.String module,
int level,
java.lang.String msg)
Deprecated. Logs an error message. |
static void |
error(java.lang.String module,
int level,
java.lang.String msg,
java.lang.Throwable t)
Deprecated. Logs an error message. |
static int |
getLevel(int type)
Deprecated. Gets the log level for a given message type. |
static MinionLog |
getLog()
Deprecated. Gets the singleton log object. |
static int |
getLogLevel(int type)
Deprecated. Gets the log level for a given message type. |
static void |
log(java.lang.String module,
int level,
java.lang.String msg)
Deprecated. Logs a log message to the log stream. |
static void |
log(java.lang.String module,
int level,
java.lang.String msg,
java.lang.Throwable t)
Deprecated. Logs a log message to the log stream. |
void |
newProperties(com.sun.labs.util.props.PropertySheet ps)
Deprecated. |
static void |
setLevel(int ll)
Deprecated. Sets the log level for all message types. |
static void |
setLevel(int type,
int ll)
Deprecated. Sets the log level for a particular message type. |
static void |
setLogger(java.util.logging.Logger logger)
Deprecated. |
static void |
setStream(int s,
java.io.OutputStream os)
Deprecated. Sets one of the streams. |
static void |
setStream(java.io.OutputStream os)
Deprecated. Sets the all the logs to the same stream. |
static void |
setStream(java.io.PrintWriter pw)
Deprecated. Sets the all the logs to the same writer. |
static void |
warn(java.lang.String module,
int level,
java.lang.String msg)
Deprecated. Logs a warning message. |
static void |
warn(java.lang.String module,
int level,
java.lang.String msg,
java.lang.Throwable t)
Deprecated. Logs a warning message. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
@ConfigString(mandatory=false) public static final java.lang.String PROP_LOG_FILE
protected static MinionLog instance
protected static int[] logLevels
protected static java.io.OutputStream[] streams
protected static java.io.PrintWriter[] writers
PrintWriters associated with the streams.
public static final int LOG
public static final int WARN
public static final int ERROR
public static final int DEBUG
| Constructor Detail |
|---|
public MinionLog()
| Method Detail |
|---|
public static MinionLog getLog()
public static int getLogLevel(int type)
type - The type of message we want the level for.
public static int getLevel(int type)
type - The type of message we want the level for.
public static void setLevel(int ll)
ll - The logging level.
public static void setLevel(int type,
int ll)
type - The type of message that we want to set the logging
level for.ll - The logging level.public static void setLogger(java.util.logging.Logger logger)
public static void setStream(java.io.OutputStream os)
os - The stream that logging data will be sent to. A null
value will disable all logging.public static void setStream(java.io.PrintWriter pw)
pw - The printwriter that logging data will be sent to. A null
value will disable all logging.
public static void setStream(int s,
java.io.OutputStream os)
s - The stream to set.os - The stream that logging data will be sent to. A null
value will disable logging for that message type.
public static void log(java.lang.String module,
int level,
java.lang.String msg)
module - The module that is reportinglevel - The level of the current messagemsg - The message to send to the log.
public static void log(java.lang.String module,
int level,
java.lang.String msg,
java.lang.Throwable t)
module - The module that is reportinglevel - The level of the current messagemsg - The message to send to the log.t - A throwable that we can print a stack trace for.
public static void warn(java.lang.String module,
int level,
java.lang.String msg)
module - The module that is reportinglevel - The level of the current messagemsg - The message to send to the log.
public static void warn(java.lang.String module,
int level,
java.lang.String msg,
java.lang.Throwable t)
module - The module that is reportinglevel - The level of the current messagemsg - The message to send to the log.t - A throwable that we can print a stack trace for.
public static void error(java.lang.String module,
int level,
java.lang.String msg)
module - The module that is reportinglevel - The level of the current messagemsg - The message to send to the log.
public static void error(java.lang.String module,
int level,
java.lang.String msg,
java.lang.Throwable t)
module - The module that is reportinglevel - The level of the current messagemsg - The message to send to the log.t - A throwable that we can print a stack trace for.
public static void debug(java.lang.String module,
int level,
java.lang.String msg)
module - The module that is reportinglevel - The level of the current messagemsg - The message to send to the log.
public static void debug(java.lang.String module,
int level,
java.lang.String msg,
java.lang.Throwable t)
module - The module that is reportinglevel - The level of the current messagemsg - The message to send to the log.t - A throwable that we can print a stack trace for.
public void newProperties(com.sun.labs.util.props.PropertySheet ps)
throws com.sun.labs.util.props.PropertyException
newProperties in interface com.sun.labs.util.props.Configurablecom.sun.labs.util.props.PropertyException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||