|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.geotools.util.logging.LoggerFactory<org.apache.commons.logging.Log>
org.geotools.util.logging.CommonsLoggerFactory
public class CommonsLoggerFactory
A factory for loggers that redirect all Java logging events to the Apache's Commons-logging framework.
Constructor Summary | |
---|---|
protected |
CommonsLoggerFactory()
Constructs a default factory. |
Method Summary | |
---|---|
protected org.apache.commons.logging.Log |
getImplementation(java.lang.String name)
Returns the implementation to use for the logger of the specified name, or null if the logger would delegates to Java logging anyway. |
static CommonsLoggerFactory |
getInstance()
Returns the unique instance of this factory. |
protected org.apache.commons.logging.Log |
unwrap(java.util.logging.Logger logger)
Returns the implementation wrapped by the specified logger, or null if none. |
protected java.util.logging.Logger |
wrap(java.lang.String name,
org.apache.commons.logging.Log implementation)
Wraps the specified implementation in a Java logger. |
Methods inherited from class org.geotools.util.logging.LoggerFactory |
---|
getImplementationClass, getLogger |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected CommonsLoggerFactory() throws java.lang.NoClassDefFoundError
java.lang.NoClassDefFoundError
- if Apache's Log
class was not found on the classpath.Method Detail |
---|
public static CommonsLoggerFactory getInstance() throws java.lang.NoClassDefFoundError
java.lang.NoClassDefFoundError
- if Apache's Log
class was not found on the classpath.protected org.apache.commons.logging.Log getImplementation(java.lang.String name)
null
if the logger would delegates to Java logging anyway.
getImplementation
in class LoggerFactory<org.apache.commons.logging.Log>
name
- The name of the logger.
null
if the target framework would redirect
to the Java logging framework.protected java.util.logging.Logger wrap(java.lang.String name, org.apache.commons.logging.Log implementation)
wrap
in class LoggerFactory<org.apache.commons.logging.Log>
name
- The name of the logger.implementation
- An implementation returned by LoggerFactory.getImplementation(java.lang.String)
.
protected org.apache.commons.logging.Log unwrap(java.util.logging.Logger logger)
null
if none.
unwrap
in class LoggerFactory<org.apache.commons.logging.Log>
logger
- The logger to test.
null
if none.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |