public abstract class LogFactory extends Object
* Factory for creating Log instances, with discovery and configuration features similar to that employed by standard Java APIs such as JAXP. *
* IMPLEMENTATION NOTE - This implementation is heavily based on the SAXParserFactory and DocumentBuilderFactory implementations * (corresponding to the JAXP pluggability APIs) found in Apache Xerces. *
* * @author Craig R. McClanahan * @author Costin Manolache * @author Richard A. Sitze * @version $Revision: 593798 $ $Date: 2007-11-10 18:40:43 +0100 $| Modifier and Type | Field and Description |
|---|---|
static String |
DIAGNOSTICS_DEST_PROPERTY |
protected static Hashtable |
factories |
static String |
FACTORY_DEFAULT |
static String |
FACTORY_PROPERTIES |
static String |
FACTORY_PROPERTY |
static String |
HASHTABLE_IMPLEMENTATION_PROPERTY |
protected static LogFactory |
nullClassLoaderFactory |
static String |
PRIORITY_KEY |
protected static String |
SERVICE_ID |
static String |
TCCL_KEY |
| Modifier | Constructor and Description |
|---|---|
protected |
LogFactory() |
| Modifier and Type | Method and Description |
|---|---|
protected static Object |
createFactory(String factoryClass,
ClassLoader classLoader) |
protected static ClassLoader |
directGetContextClassLoader() |
abstract Object |
getAttribute(String name) |
abstract String[] |
getAttributeNames() |
protected static ClassLoader |
getClassLoader(Class clazz) |
protected static ClassLoader |
getContextClassLoader() |
static LogFactory |
getFactory() |
abstract Log |
getInstance(Class clazz) |
abstract Log |
getInstance(String name) |
static Log |
getLog(Class clazz) |
static Log |
getLog(String name) |
protected static boolean |
isDiagnosticsEnabled() |
protected static void |
logRawDiagnostic(String msg) |
protected static LogFactory |
newFactory(String factoryClass,
ClassLoader classLoader) |
protected static LogFactory |
newFactory(String factoryClass,
ClassLoader classLoader,
ClassLoader contextClassLoader) |
static String |
objectId(Object o) |
abstract void |
release() |
static void |
release(ClassLoader classLoader) |
static void |
releaseAll() |
abstract void |
removeAttribute(String name) |
abstract void |
setAttribute(String name,
Object value) |
public static final String PRIORITY_KEY
public static final String TCCL_KEY
public static final String FACTORY_PROPERTY
public static final String FACTORY_DEFAULT
public static final String FACTORY_PROPERTIES
protected static final String SERVICE_ID
public static final String DIAGNOSTICS_DEST_PROPERTY
public static final String HASHTABLE_IMPLEMENTATION_PROPERTY
protected static Hashtable factories
protected static LogFactory nullClassLoaderFactory
public abstract String[] getAttributeNames()
public abstract Log getInstance(Class clazz) throws LogConfigurationException
LogConfigurationExceptionpublic abstract Log getInstance(String name) throws LogConfigurationException
LogConfigurationExceptionpublic abstract void release()
public abstract void removeAttribute(String name)
public static LogFactory getFactory() throws LogConfigurationException
LogConfigurationExceptionpublic static Log getLog(Class clazz) throws LogConfigurationException
LogConfigurationExceptionpublic static Log getLog(String name) throws LogConfigurationException
LogConfigurationExceptionpublic static void release(ClassLoader classLoader)
public static void releaseAll()
protected static ClassLoader getClassLoader(Class clazz)
protected static ClassLoader getContextClassLoader() throws LogConfigurationException
LogConfigurationExceptionprotected static ClassLoader directGetContextClassLoader() throws LogConfigurationException
LogConfigurationExceptionprotected static LogFactory newFactory(String factoryClass, ClassLoader classLoader, ClassLoader contextClassLoader) throws LogConfigurationException
LogConfigurationExceptionprotected static LogFactory newFactory(String factoryClass, ClassLoader classLoader)
protected static Object createFactory(String factoryClass, ClassLoader classLoader)
protected static boolean isDiagnosticsEnabled()
protected static final void logRawDiagnostic(String msg)
Copyright © 2014. All rights reserved.