Logger class abstract
Abstract logger that captures and formats log messages. Child classes take the captured messages and write them to their specific destinations.
Configuration parameters
Parameters to pass to the configure method for component configuration:
level
: maximum log level to capture- source: source (context) name
References
- *:context-info:*:*:1.0 (optional) ContextInfo to detect the context id and specify counters source
See ILogger
- Implemented types
- Implementers
Constructors
- Logger()
- Creates a new instance of the logger.
Properties
Methods
-
composeError(
Exception error) → String - Composes an human-readable error description
-
configure(
ConfigParams config) → void - Configures component by passing configuration parameters.
-
debug(
String? correlationId, String message, [List? args]) → void -
Logs a high-level debug information for troubleshooting.
override
-
error(
String? correlationId, Exception? error, String message, [List? args]) → void -
Logs recoverable application error.
override
-
fatal(
String? correlationId, Exception? error, String message, [List? args]) → void -
Logs fatal (unrecoverable) message that caused the process to crash.
override
-
getLevel(
) → LogLevel -
Gets the maximum log level.
Messages with higher log level are filtered out.
override
-
getSource(
) → String? - Gets the source (context) name.
-
info(
String? correlationId, String message, [List? args]) → void -
Logs an important information message
override
-
log(
LogLevel level, String? correlationId, Exception? error, String message, [List? args]) → void -
Logs a message at specified log level.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
setLevel(
LogLevel value) → void -
Set the maximum log level.
override
-
setReferences(
IReferences references) → void - Sets references to dependent components.
-
setSource(
String value) → void - Sets the source (context) name.
-
toString(
) → String -
A string representation of this object.
inherited
-
trace(
String? correlationId, String message, [List? args]) → void -
Logs a low-level debug information for troubleshooting.
override
-
warn(
String? correlationId, String message, [List? args]) → void -
Logs a warning that may or may not have a negative impact.
override
-
write(
LogLevel level, String? correlationId, Exception? error, String message) → void - Writes a log message to the logger destination.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited