|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mmbase.util.logging.AbstractSimpleImpl
public abstract class AbstractSimpleImpl
Base class for simple Logger implementations (no patterns and so on).
| Field Summary | |
|---|---|
protected int |
level
|
| Constructor Summary | |
|---|---|
AbstractSimpleImpl()
|
|
| Method Summary | |
|---|---|
void |
debug(Object m)
Logs the message m with debug priority. |
void |
debug(Object m,
Throwable t)
|
void |
error(Object m)
Logs the message m with error priority. |
void |
error(Object m,
Throwable t)
|
void |
fatal(Object m)
Logs the message m with fatal priority. |
void |
fatal(Object m,
Throwable t)
|
static MDC |
getMDC()
|
void |
info(Object m)
Logs the message m with info priority. |
void |
info(Object m,
Throwable t)
|
boolean |
isDebugEnabled()
Returns true if for this category (Logger), a call to debug (or trace) would do something. |
boolean |
isEnabledFor(Level l)
|
boolean |
isServiceEnabled()
Returns true if for this category (Logger), a call to service (or debug or trace) would do something. |
boolean |
isTraceEnabled()
Returns true if for this category (Logger), a call to trace would do something. |
protected void |
log(Object s,
Level level)
Override to implement different stringification of objects to log. |
protected void |
log(Object s,
Level level,
Throwable t)
|
protected void |
log(String s)
How to write one string. |
protected void |
log(String s,
Level level)
Logs a message for a certain string. |
void |
service(Object m)
Logs the message m with service priority. |
void |
service(Object m,
Throwable t)
|
void |
setLevel(Level p)
If you want to override the level in the configuration file fixed for this category, you can do it with this method. |
void |
trace(Object m)
Logs the message m with trace priority. |
void |
trace(Object m,
Throwable t)
|
void |
warn(Object m)
Logs the message m with warn priority. |
void |
warn(Object m,
Throwable t)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected int level
| Constructor Detail |
|---|
public AbstractSimpleImpl()
| Method Detail |
|---|
public static MDC getMDC()
public void setLevel(Level p)
Logger
setLevel in interface Loggerp - The level of the priority. One of the constants
Level.TRACE, Level.DEBUG, Level.SERVICE, Level.INFO,
Level.WARN, Level.ERROR or Level.FATAL.protected void log(String s)
log(String, Level). Default this does
nothing, you must override this, or log(String, Level).
protected void log(String s,
Level level)
log(String) where the string is
prefixed with the level. Override this one if you want it differently.
protected void log(Object s,
Level level)
protected void log(Object s,
Level level,
Throwable t)
public void trace(Object m)
Logger
trace in interface LoggerLogger.debug(Object)
public void trace(Object m,
Throwable t)
trace in interface Loggerpublic void debug(Object m)
Logger
debug in interface Logger
public void debug(Object m,
Throwable t)
debug in interface Loggerpublic void service(Object m)
Logger
service in interface Logger
public void service(Object m,
Throwable t)
service in interface Loggerpublic void info(Object m)
Logger
info in interface Logger
public void info(Object m,
Throwable t)
info in interface Loggerpublic void warn(Object m)
Logger
warn in interface Logger
public void warn(Object m,
Throwable t)
warn in interface Loggerpublic void error(Object m)
Logger
error in interface Logger
public void error(Object m,
Throwable t)
error in interface Loggerpublic void fatal(Object m)
Logger
fatal in interface Logger
public void fatal(Object m,
Throwable t)
fatal in interface Loggerpublic boolean isTraceEnabled()
Logger
isTraceEnabled in interface Loggerpublic boolean isDebugEnabled()
Logger
isDebugEnabled in interface Loggerpublic boolean isServiceEnabled()
Logger
isServiceEnabled in interface Loggerpublic boolean isEnabledFor(Level l)
isEnabledFor in interface Logger
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||