|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcz.cuni.amis.pogamut.base.utils.logging.AbstractLogCategories
public abstract class AbstractLogCategories
Class that wraps the map with log categories. It allows you to simply create new categories or query it's mapping.
The only constructor LogCategories(Logger) is protected and is instantiated during the construction of AgentLogger.
Constructor Summary | |
---|---|
AbstractLogCategories()
|
Method Summary | |
---|---|
void |
addLogCategory(String name,
LogCategory category)
Used by AbstractAgentLogger to slip itself into the map. |
Map<String,LogCategory> |
getCategories()
Returns IMMUTABLE mapping of cathegories names to instances of those log categories. |
protected abstract Map<String,LogCategory> |
getCategoriesInternal()
|
String[] |
getCategoryNames()
Returns names of all existing log categories. |
String[] |
getCategoryNamesSorted()
Returns names of all existing log categories sorted alphabetically. |
boolean |
hasCategory(String name)
Whether some category with specified name exists. |
void |
setLevel(Level newLevel)
Set level for all handlers of all categories. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface cz.cuni.amis.pogamut.base.utils.logging.ILogCategories |
---|
getCategory |
Constructor Detail |
---|
public AbstractLogCategories()
Method Detail |
---|
protected abstract Map<String,LogCategory> getCategoriesInternal()
public boolean hasCategory(String name)
hasCategory
in interface ILogCategories
name
-
public Map<String,LogCategory> getCategories()
You have to synchronize on it before iterating through it!
getCategories
in interface ILogCategories
public void addLogCategory(String name, LogCategory category)
AbstractAgentLogger
to slip itself into the map.
addLogCategory
in interface ILogCategories
name
- category
- public String[] getCategoryNames()
getCategoryNames
in interface ILogCategories
public String[] getCategoryNamesSorted()
getCategoryNamesSorted
in interface ILogCategories
public void setLevel(Level newLevel)
setLevel
in interface ILogCategories
newLevel
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |