public final class

NOPLoggerRepository

extends Object
implements LoggerRepository
java.lang.Object
   ↳ org.apache.log4j.spi.NOPLoggerRepository

Class Overview

No-operation implementation of LoggerRepository which is used when LogManager.repositorySelector is erroneously nulled during class reloading.

Summary

Public Constructors
NOPLoggerRepository()
Public Methods
void addHierarchyEventListener(HierarchyEventListener listener)
Add a HierarchyEventListener event to the repository.
void emitNoAppenderWarning(Category cat)
Logger exists(String name)
void fireAddAppenderEvent(Category logger, Appender appender)
Enumeration getCurrentCategories()
Deprecated.
Enumeration getCurrentLoggers()
Logger getLogger(String name)
Logger getLogger(String name, LoggerFactory factory)
Logger getRootLogger()
Level getThreshold()
Get the repository-wide threshold.
boolean isDisabled(int level)
Returns whether this repository is disabled for a given level.
void resetConfiguration()
void setThreshold(String val)
Another form of setThreshold(Level) accepting a string parameter instead of a Level.
void setThreshold(Level level)
Set the repository-wide threshold.
void shutdown()
[Expand]
Inherited Methods
From class java.lang.Object
From interface org.apache.log4j.spi.LoggerRepository

Public Constructors

public NOPLoggerRepository ()

Public Methods

public void addHierarchyEventListener (HierarchyEventListener listener)

Add a HierarchyEventListener event to the repository.

public void emitNoAppenderWarning (Category cat)

public Logger exists (String name)

public void fireAddAppenderEvent (Category logger, Appender appender)

public Enumeration getCurrentCategories ()

Deprecated. Please use getCurrentLoggers() instead.

public Enumeration getCurrentLoggers ()

public Logger getLogger (String name)

public Logger getLogger (String name, LoggerFactory factory)

public Logger getRootLogger ()

public Level getThreshold ()

Get the repository-wide threshold. See setThreshold(Level) for an explanation.

public boolean isDisabled (int level)

Returns whether this repository is disabled for a given level. The answer depends on the repository threshold and the level parameter. See also setThreshold(String) method.

public void resetConfiguration ()

public void setThreshold (String val)

Another form of setThreshold(Level) accepting a string parameter instead of a Level.

public void setThreshold (Level level)

Set the repository-wide threshold. All logging requests below the threshold are immediately dropped. By default, the threshold is set to Level.ALL which has the lowest possible rank.

public void shutdown ()