it.andynaz.log
public class LoggerMgr extends Object
defaultLogger
"
in the ConfigMgr
class. The logger used should have two constructors,
the one with no arguments and another one with takes a string.
The logger is created using the configuration stored in the ConfigMgr
class. If the class specified by the value "defaultLogger
"
does not exist or it is not a subclass of Logger
, a Logger
is
created (the one that uses the standard output).
Warning: getLogger
methods do no returns any more loggers
created with the shared configuration from Config
class, but only
from the one obtained by the ConfigMgr
one.
Modifier | Constructor and Description |
---|---|
private |
LoggerMgr() |
Modifier and Type | Method and Description |
---|---|
static Logger |
getLogger()
Returns a "default" logger without a name.
|
static Logger |
getLogger(String name)
Returnes a "default" logger with a name.
|
private static Class<Logger> |
getLoggerClass()
Returns the class used to create the logger.
|
public static Logger getLogger()
Logger
in caso of
errorspublic static Logger getLogger(String name)
name
- the name of the loggerLogger
in case of errors) with a
name© 2013 andynaz - http://andynaz.altervista.org