|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.util.logging.Logger
org.objectweb.util.monolog.wrapper.javaLog.Logger
public class Logger
Is an extension of the java.util.logging.Logger class used to wrap Monolog on the logging system provided in the JDK since the 1.4 version.
| Field Summary | |
|---|---|
protected Logger |
inner
This fieds is the real logger. |
| Fields inherited from class java.util.logging.Logger |
|---|
global, GLOBAL_LOGGER_NAME |
| Fields inherited from interface org.objectweb.util.monolog.api.Handler |
|---|
APPEND_MODE_ATTRIBUTE, BUFFER_ATTRIBUTE, CONSOLE_HANDLER_TYPE, FILE_HANDLER_TYPE, FILE_NUMBER_ATTRIBUTE, GENERIC_HANDLER_TYPE, JMX_HANDLER_TYPE, LEVEL_ATTRIBUTE, LOGGER_HANDLER_TYPE, MAX_SIZE_ATTRIBUTE, OUTPUT_ATTRIBUTE, PATTERN_ATTRIBUTE, ROLLING_FILE_HANDLER_TYPE |
| Constructor Summary | |
|---|---|
protected |
Logger(Logger inner)
Builds a a Logger with an inner logger |
protected |
Logger(String name,
String resName)
Builds a Logger without inner logger (==> inner = this) |
| Method Summary | |
|---|---|
void |
addHandler(Handler handler)
|
void |
addHandler(Handler h)
A TopicalLogger manages a list of Handler instances. |
void |
addTopic(String topic)
This method allows adding a topic to a TopicalLogger. |
boolean |
getAdditivity()
It retrieves the additivity flag for this logger instance. |
Object |
getAttribute(String name)
It retrieves the value of an attribute value of the handler. |
String[] |
getAttributeNames()
It retrieves the attributes of the handler |
int |
getCurrentIntLevel()
|
Level |
getCurrentLevel()
|
Handler[] |
getHandler()
Get the Handlers associated with this logger. |
Handler |
getHandler(String hn)
It returns the handler which the name is equals to the parameter |
String[] |
getTopic()
This method allows getting a topic list of this TopicalLogger. |
Enumeration |
getTopics()
This method allows getting a topic list of this TopicalLogger. |
String |
getType()
It retrieves the Handler type |
boolean |
isLoggable(int l)
|
boolean |
isLoggable(Level l)
|
boolean |
isOn()
|
void |
log(int l,
Object o)
|
void |
log(int level,
Object o,
Object location,
Object method)
|
void |
log(int l,
Object o,
Throwable t)
|
void |
log(int level,
Object o,
Throwable t,
Object location,
Object method)
|
void |
log(Level l,
Object o)
|
void |
log(Level l,
Object o,
Object location,
Object method)
|
void |
log(Level l,
Object o,
Throwable t)
|
void |
log(Level l,
Object o,
Throwable t,
Object location,
Object method)
|
void |
removeAllHandlers()
A TopicalLogger manages a list of Handler instances. |
void |
removeHandler(Handler h)
A TopicalLogger manages a list of Handler instances. |
void |
removeTopic(String topic)
This method allows removing a topic to a TopicalLogger. |
void |
setAdditivity(boolean a)
It assigns the additivity flag for this logger instance. |
Object |
setAttribute(String name,
Object value)
It assigns an attributte to the handler. |
void |
setIntLevel(int level)
|
void |
setLevel(Level l)
|
void |
setName(String name)
It assigns the name of the handler |
void |
turnOff()
|
void |
turnOn()
|
| Methods inherited from class java.util.logging.Logger |
|---|
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, setLevel, setParent, setUseParentHandlers, severe, throwing, warning |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.objectweb.util.monolog.api.Handler |
|---|
getName |
| Field Detail |
|---|
protected Logger inner
| Constructor Detail |
|---|
protected Logger(Logger inner)
inner - the real logger
protected Logger(String name,
String resName)
name - is the loggerNameresName - is the resource bundle name| Method Detail |
|---|
public void addHandler(Handler handler)
addHandler in class Loggerpublic void setName(String name)
setName in interface Handlerpublic String getType()
getType in interface Handlerpublic String[] getAttributeNames()
getAttributeNames in interface Handlerpublic Object getAttribute(String name)
getAttribute in interface Handlername - is an attribute name
public Object setAttribute(String name,
Object value)
setAttribute in interface Handlername - is the attribute namevalue - is the attribute value
public void addHandler(Handler h)
throws Exception
addHandler in interface TopicalLoggerExceptionpublic Handler getHandler(String hn)
getHandler in interface TopicalLoggerhn - is the handler name
public Handler[] getHandler()
getHandler in interface TopicalLogger
public void removeHandler(Handler h)
throws Exception
removeHandler in interface TopicalLoggerException
public void removeAllHandlers()
throws Exception
removeAllHandlers in interface TopicalLoggerExceptionpublic void setAdditivity(boolean a)
setAdditivity in interface TopicalLoggerpublic boolean getAdditivity()
getAdditivity in interface TopicalLogger
public void addTopic(String topic)
throws Exception
addTopic in interface TopicalLoggerExceptionpublic String[] getTopic()
getTopic in interface TopicalLoggerpublic Enumeration getTopics()
getTopics in interface TopicalLogger
public void removeTopic(String topic)
throws Exception
removeTopic in interface TopicalLoggerExceptionpublic void setIntLevel(int level)
setIntLevel in interface Loggerpublic void setLevel(Level l)
setLevel in interface Loggerpublic int getCurrentIntLevel()
getCurrentIntLevel in interface Loggerpublic Level getCurrentLevel()
getCurrentLevel in interface Loggerpublic boolean isLoggable(int l)
isLoggable in interface Loggerpublic boolean isLoggable(Level l)
isLoggable in interface Loggerpublic boolean isOn()
isOn in interface Logger
public void log(int l,
Object o)
log in interface Logger
public void log(Level l,
Object o)
log in interface Logger
public void log(int l,
Object o,
Throwable t)
log in interface Logger
public void log(Level l,
Object o,
Throwable t)
log in interface Logger
public void log(int level,
Object o,
Object location,
Object method)
log in interface Logger
public void log(Level l,
Object o,
Object location,
Object method)
log in interface Logger
public void log(int level,
Object o,
Throwable t,
Object location,
Object method)
log in interface Logger
public void log(Level l,
Object o,
Throwable t,
Object location,
Object method)
log in interface Loggerpublic void turnOn()
turnOn in interface Loggerpublic void turnOff()
turnOff in interface Logger
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||