org.universAAL.middleware.container
Interface LogListener
public interface LogListener
Listener interface for new log entries. The log listeners are called
automatically when adding a log entry to
LogUtils
.
To use this method, create a class (e.g. LogMonitor) that implements
this interface and register the OSGi service, i.e.:
context.registerService(new String[] { LogListener.class.getName() },
new LogMonitor(), null);
- Author:
- Carsten Stockloew
LOG_LEVEL_TRACE
static final int LOG_LEVEL_TRACE
- See Also:
- Constant Field Values
LOG_LEVEL_DEBUG
static final int LOG_LEVEL_DEBUG
- See Also:
- Constant Field Values
LOG_LEVEL_INFO
static final int LOG_LEVEL_INFO
- See Also:
- Constant Field Values
LOG_LEVEL_WARN
static final int LOG_LEVEL_WARN
- See Also:
- Constant Field Values
LOG_LEVEL_ERROR
static final int LOG_LEVEL_ERROR
- See Also:
- Constant Field Values
log
void log(int logLevel,
String module,
String pkg,
String cls,
String method,
Object[] msgPart,
Throwable t)
- Log a new message.
- Parameters:
logLevel
- the log level (trace, debug, info, warn, or error)module
- the name of the module that contains the class that intends to
generate the log messagepkg
- the name of the package that contains the class that intends
to generate the log messagecls
- the name of the class that intends to generate the log messagemethod
- The name of the method in the above Java class that intends to
generate the log messagemsgPart
- An array of strings and other objects that should be
concatenated using String.valueOf(Object)
in
order to construct the log messaget
- An optional Throwable
object like an
exception that might have caused the log request
Copyright © 2014 universAAL Consortium. All Rights Reserved.