org.as2lib.core.BasicInterface +--org.as2lib.env.log.Logger +--org.as2lib.env.log.ConfigurableLogger
ConfigurableLogger
declares methods needed to configure most loggers.
This is first the method to set the level setLevel and second the methods to add, remove and access handlers addHandler, removeHandler, removeAllHandlers and getAllHandlers.
Log handlers are responsible for making the actual output. There are a few
pre-defined handlers that can be used to log to different output devices. Take
a look at the org.as2lib.env.log.handler
package for these.
Loggers are normally configured only once.
debug(), error(), fatal(), info(), isDebugEnabled(), isErrorEnabled(), isFatalEnabled(), isInfoEnabled(), isWarningEnabled(), warning()
public function setLevel(level:LogLevel):Void
Sets the log level.
The level determines which output to make and and which to make not.
level | the new level to control the output |
public function addHandler(handler:LogHandler):Void
Adds the passed-in log handler
.
Log handlers are used to actually log the messages. They determine what information to log and to which output device.
handler | the new log handler to log messages |
public function getAllHandlers(Void):Array
Returns all handlers that were added to this logger.
all added log handlers
public function removeHandler(handler:LogHandler):Void
Removes all occerrences of the passed-in handler
.
handler | the log handler to remove |