Class AppenderAdmin

java.lang.Object
org.apache.logging.log4j.core.jmx.AppenderAdmin
All Implemented Interfaces:
AppenderAdminMBean

public class AppenderAdmin extends Object implements AppenderAdminMBean
Implementation of the AppenderAdminMBean interface.
  • Constructor Details

    • AppenderAdmin

      public AppenderAdmin(String contextName, Appender appender)
      Constructs a new AppenderAdmin with the specified contextName and appender.
      Parameters:
      contextName - used in the ObjectName for this mbean
      appender - the instrumented object
  • Method Details

    • getObjectName

      public ObjectName getObjectName()
      Returns the ObjectName of this mbean.
      Returns:
      the ObjectName
      See Also:
    • getName

      public String getName()
      Description copied from interface: AppenderAdminMBean
      Returns the name of the instrumented Appender.
      Specified by:
      getName in interface AppenderAdminMBean
      Returns:
      the name of the Appender
    • getLayout

      public String getLayout()
      Description copied from interface: AppenderAdminMBean
      Returns the result of calling toString on the Layout object of the instrumented Appender.
      Specified by:
      getLayout in interface AppenderAdminMBean
      Returns:
      the Layout of the instrumented Appender as a string
    • isIgnoreExceptions

      public boolean isIgnoreExceptions()
      Description copied from interface: AppenderAdminMBean
      Returns how exceptions thrown on the instrumented Appender are handled.
      Specified by:
      isIgnoreExceptions in interface AppenderAdminMBean
      Returns:
      true if any exceptions thrown by the Appender will be logged or false if such exceptions are re-thrown.
    • getErrorHandler

      public String getErrorHandler()
      Description copied from interface: AppenderAdminMBean
      Returns the result of calling toString on the error handler of this appender, or "null" if no error handler was set.
      Specified by:
      getErrorHandler in interface AppenderAdminMBean
      Returns:
      result of calling toString on the error handler of this appender, or "null"
    • getFilter

      public String getFilter()
      Description copied from interface: AppenderAdminMBean
      Returns a string description of all filters configured for the instrumented Appender.
      Specified by:
      getFilter in interface AppenderAdminMBean
      Returns:
      a string description of all configured filters for this appender