Package de.mnl.osgi.log4j2osgi
Class OsgiLoggerContext
- java.lang.Object
-
- de.mnl.osgi.log4j2osgi.OsgiLoggerContext
-
- All Implemented Interfaces:
de.mnl.osgi.lf4osgi.core.LoggerGroup,org.apache.logging.log4j.spi.LoggerContext
public class OsgiLoggerContext extends Object implements de.mnl.osgi.lf4osgi.core.LoggerGroup, org.apache.logging.log4j.spi.LoggerContext
The OsgiLoggerContext.
-
-
Constructor Summary
Constructors Constructor Description OsgiLoggerContext(Bundle bundle)Instantiates a new OSGi logger context.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BundlegetBundle()ObjectgetExternalContext()OsgiLoggergetLogger(String name)org.apache.logging.log4j.spi.ExtendedLoggergetLogger(String name, org.apache.logging.log4j.message.MessageFactory messageFactory)booleanhasLogger(String name)booleanhasLogger(String name, Class<? extends org.apache.logging.log4j.message.MessageFactory> messageFactoryClass)booleanhasLogger(String name, org.apache.logging.log4j.message.MessageFactory messageFactory)
-
-
-
Constructor Detail
-
OsgiLoggerContext
public OsgiLoggerContext(Bundle bundle)
Instantiates a new OSGi logger context.- Parameters:
bundle- the bundle
-
-
Method Detail
-
getBundle
public Bundle getBundle()
- Specified by:
getBundlein interfacede.mnl.osgi.lf4osgi.core.LoggerGroup
-
getLogger
public OsgiLogger getLogger(String name)
- Specified by:
getLoggerin interfaceorg.apache.logging.log4j.spi.LoggerContext
-
getLogger
public org.apache.logging.log4j.spi.ExtendedLogger getLogger(String name, org.apache.logging.log4j.message.MessageFactory messageFactory)
- Specified by:
getLoggerin interfaceorg.apache.logging.log4j.spi.LoggerContext
-
hasLogger
public boolean hasLogger(String name)
- Specified by:
hasLoggerin interfaceorg.apache.logging.log4j.spi.LoggerContext
-
hasLogger
public boolean hasLogger(String name, org.apache.logging.log4j.message.MessageFactory messageFactory)
- Specified by:
hasLoggerin interfaceorg.apache.logging.log4j.spi.LoggerContext
-
hasLogger
public boolean hasLogger(String name, Class<? extends org.apache.logging.log4j.message.MessageFactory> messageFactoryClass)
- Specified by:
hasLoggerin interfaceorg.apache.logging.log4j.spi.LoggerContext
-
getExternalContext
public Object getExternalContext()
- Specified by:
getExternalContextin interfaceorg.apache.logging.log4j.spi.LoggerContext
-
-