public class LoggerConfigAdmin extends Object implements LoggerConfigAdminMBean
LoggerConfigAdminMBean
interface.PATTERN
Constructor and Description |
---|
LoggerConfigAdmin(LoggerContext loggerContext,
LoggerConfig loggerConfig)
Constructs a new
LoggerConfigAdmin with the specified LoggerContext
and logger config. |
Modifier and Type | Method and Description |
---|---|
String[] |
getAppenderRefs()
Returns a String array with the appender refs configured for the
instrumented
LoggerConfig . |
String |
getFilter()
Returns a string description of all filters configured for the
instrumented
LoggerConfig . |
String |
getLevel()
Returns the
LoggerConfig level as a String. |
String |
getName()
Returns the name of the instrumented
LoggerConfig . |
ObjectName |
getObjectName()
Returns the
ObjectName of this mbean. |
boolean |
isAdditive()
Returns whether the instrumented
LoggerConfig is additive. |
boolean |
isIncludeLocation()
Returns whether the instrumented
LoggerConfig is configured to
include location. |
void |
setAdditive(boolean additive)
Sets whether the instrumented
LoggerConfig should be additive. |
void |
setLevel(String level)
Sets the
LoggerConfig level to the specified value. |
public LoggerConfigAdmin(LoggerContext loggerContext, LoggerConfig loggerConfig)
LoggerConfigAdmin
with the specified LoggerContext
and logger config.loggerContext
- used in the ObjectName
for this mbeanloggerConfig
- the instrumented objectpublic ObjectName getObjectName()
ObjectName
of this mbean.ObjectName
LoggerConfigAdminMBean.PATTERN
public String getName()
LoggerConfigAdminMBean
LoggerConfig
.getName
in interface LoggerConfigAdminMBean
public String getLevel()
LoggerConfigAdminMBean
LoggerConfig
level as a String.getLevel
in interface LoggerConfigAdminMBean
LoggerConfig
level.public void setLevel(String level)
LoggerConfigAdminMBean
LoggerConfig
level to the specified value.setLevel
in interface LoggerConfigAdminMBean
level
- the new LoggerConfig
level.public boolean isAdditive()
LoggerConfigAdminMBean
LoggerConfig
is additive.isAdditive
in interface LoggerConfigAdminMBean
true
if the LoggerConfig is additive, false
otherwisepublic void setAdditive(boolean additive)
LoggerConfigAdminMBean
LoggerConfig
should be additive.setAdditive
in interface LoggerConfigAdminMBean
additive
- true
if the instrumented LoggerConfig should be
additive, false
otherwisepublic boolean isIncludeLocation()
LoggerConfigAdminMBean
LoggerConfig
is configured to
include location.isIncludeLocation
in interface LoggerConfigAdminMBean
public String getFilter()
LoggerConfigAdminMBean
LoggerConfig
.getFilter
in interface LoggerConfigAdminMBean
public String[] getAppenderRefs()
LoggerConfigAdminMBean
LoggerConfig
.getAppenderRefs
in interface LoggerConfigAdminMBean
LoggerConfig
.Copyright © 1999-2021 Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.