Package org.apache.log4j.chainsaw
Class LoggerNameModelSupport
java.lang.Object
org.apache.log4j.chainsaw.LoggerNameModelSupport
- All Implemented Interfaces:
LoggerNameModel
An implementation of LoggerNameModel which can be used as a delegate
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
addLoggerName
(String loggerName) Attempts to add the loggerName to the model, and returns true if it does, i.e that the loggerName is new, otherwise it is ignored.void
Returns an unmodifiable Collection of the uniquely known LoggerNames within this model.private void
notifyListeners
(String loggerName) Notifies all the registered listeners that a new unique logger name has been added to this modelvoid
void
reset()
The logger names have been cleared
-
Field Details
-
loggerNameSet
-
listenerList
-
-
Constructor Details
-
LoggerNameModelSupport
public LoggerNameModelSupport()
-
-
Method Details
-
getLoggerNames
Description copied from interface:LoggerNameModel
Returns an unmodifiable Collection of the uniquely known LoggerNames within this model.- Specified by:
getLoggerNames
in interfaceLoggerNameModel
- Returns:
- unmodifiable Collection of Logger name Strings
-
addLoggerName
Description copied from interface:LoggerNameModel
Attempts to add the loggerName to the model, and returns true if it does, i.e that the loggerName is new, otherwise it is ignored.If the loggerName is new for this model, all the LoggerNameListeners are notified using this thread.
- Specified by:
addLoggerName
in interfaceLoggerNameModel
-
reset
public void reset()Description copied from interface:LoggerNameModel
The logger names have been cleared- Specified by:
reset
in interfaceLoggerNameModel
-
notifyListeners
Notifies all the registered listeners that a new unique logger name has been added to this model- Parameters:
loggerName
-
-
addLoggerNameListener
- Specified by:
addLoggerNameListener
in interfaceLoggerNameModel
-
removeLoggerNameListener
- Specified by:
removeLoggerNameListener
in interfaceLoggerNameModel
-