Protected
_categoryThe fallback category, if none is specified via the category() method.
Protected
_localStores logger-local appenders.
Protected
_onceStores ids of messages that are to be logged only once.
Protected
_originA fallback origin, if none is specified via the origin() method. If the parent of this logger is set, it derives its origin from there.
Protected
_parentThe parent logger of which to optain the parent ref fragment.
Protected
_refThe ref fragment.0
Static
SeverityStatic
Protected
_rootThe root logger.
Static
Protected
appendersThe root logger.
Static
Protected
fallCaches log messages that have not been handled due to missing fallback appender.
Static
Protected
fallbackThe root logger.
Static
rootProtected
_determineDetermines the log message origin based on the origin configured and the globally set origin. If the origins of this logger and the root are set and differ, they will be concatenated using a slash ('/).
Optional
explicitOrigin: null | stringThe origin configured in this logger is extensible by an explicit string specified.
Protected
_getProtected
_getProtected
_getIf the implementor of this interface provides a category, the category string will be determined in form of a string with the syntax 'Category.Subcategory.*'. If the category specified in this object starts with a period ('.'), it is appended to this and/or a parent logger's category.
Optional
explicitCategory: null | string | CategoryThe category specified to this object can be overridden by providing an absolute category string (not starting with period) or a category object.
Protected
_getProtected
_getProtected
_getProvides the parent log entity providing the parent ref fragment, origin and category.
Protected
_getProtected
_getThe implementor of this interface provides a ref fragment, else, a parent's ref will be used. If it also provides a parent logger entity, its ref fragment will be prepended to this ref fragment so that the resulting ref string has the syntax 'Module:SubModule:*:Class:Function' of which every element is optional.
Optional
subRef: null | stringIf specified, this ref will be appended to the logger's basic ref.
Protected
_logReceives an internal log message from a log message builder instance in order to create a corresponding log message object. The created message object is then forwared to the appender or fallback appender channel.
Adds a new appender to the logger's local appenders list. This can be used for handling logger-specific appenders.
The appender to add;
enables chaining calls to the logger
Sets a category for the next log message. The respective log method must be called on the returned object (method chaining). The returned object allows to call more parameter specifying methods. If the returned object is withdrawn, the set category information is lost. The category of the new log message defaults to the logger's category.
The category to set for the next log message. If a Category object or a string is provided, it will be used as the actual category of the message. If a string is provided that starts with a period, e.g. '.subcategory', it will be used as a sub category of the parent logger's category. The categories will then be concatenated separated by a perios ('.').
The log message builder object that allows to specify more parameters of the next log message.
Sets the next log message to be appended to the fallback appender. The respective log method must be called on the returned object (method chaining). If the returned object is withdrawn, the set fallback information is lost. This disables the evaluation of message filters to the appenders. The log framework does this internally, if errors in custom code or appenders occur.
If true, the next message will be handled by a fallback appender.
The returned object allows to call more parameter specifying methods.
Protected
getDetermines a registerable once id. If a once id is set for the message, it is used. Else, if a message id is set, it is used, prepended with the severity level. If no id is set, the message is used prepended with the severity level.
the registerable id if found, or undefined, if not available
Forwards the message to the fallback appenders.
The message to be handled.
Returns itself for the purpose ot method chaining.
Handles the log message. This implementation forwards the message to all registered appenders. If none handles the message, it will be forwarded to the fallback appenders.
The message to handle.
Returns itself for the purpose of method chaining.
Sets the id for the next log message. The respective log method must be called on the returned object (method chaining). The returned object allows to call more parameter specifying methods. If the returned object is withdrawn, the set id information is lost.
The id to set for the next log message
The log message builder object that allows to specify more parameters of the next log message.
Information about the actions that are executed by the software. For User feedback.
The actual log message.
Optional
parameters: null | objectThe log message parameters. Its keys will replace the '%key%' placeholders in the message string.
Creates a new LogMessage by calling the abstract methods in this interface.
The severity of the log message. Possible values are specified by the LogMessage.Severity Enum.
The actual log message.
Optional
parameters: null | objectThe log message parameters. Its keys will replace the '%key%' placeholders in the message string.
Sets the onceId for the new log message. The respective log method must be called on the returned object (method chaining). If the returned object is withdrawn, the set fallback information is lost. If set, other messages using the same onceid will not be handled.
Optional
onceId: string | booleanif set to true, only, the combination of loglevel, id or message text will be used for identifying similar messages
Sets the origin (current environment) for the next log message. The respective log method must be called on the returned object (method chaining). The returned object allows to call more parameter specifying methods. If the returned object is withdrawn, the set origin information is lost. The origin of the new log message defaults to the logger's origin. If providing an origin that differs from the logger's origin, the strings are concatenated separated by a slash ('/')
The origin to set for the next log message
The log message builder object that allows to specify more parameters of the next log message.
Sets a ref fragment for the next log message. The respective log method must be called on the returned object (method chaining). The returned object allows to call more parameter specifying methods. If the returned object is withdrawn, the set ref fragment information is lost. The ref fragment of the new log message defaults to the logger's ref fragment. All fragments in the chain of loggers are concatenated separated by a colon (':')
The ref fragment to set for the next log message
The log message builder object that allows to specify more parameters of the next log message.
Removes an appender from the logger's local appenders list.
The appender to remove;
enables chaining calls to the logger
Sets the category of this logger.
Sets the parent Logger for this logger.
Creates a new logger instance as a child of this logger.
The ref fragment of the source code organization unit (e.g. module, class, function) that requests the new logger.
Optional
category: null | string | CategoryThe (new sub-/root-) category of the new logger.
Optional
origin: null | stringThe origin of the new logger.
Warnings about unintended behaviour or usage of the software or possible security and safety risks.
The actual log message.
Optional
parameters: null | objectThe log message parameters. Its keys will replace the '%key%' placeholders in the message string.
Static
addAdds a new appender to the root logger.
Static
addAdds a new fallback appender. If the appender specified is the first explicit fallback appender, it will receive all cached log messages that have not been appended yet. The internal log message cache should be disabled, if no functional fallback appender is intended to be added to the log interface.
A Logger is responsible for creating the log messages and propagating these to the appenders. It is initialized with a ref fragment in order to be assigned to a specific software unit. In order to provide fully qualified refs, the loggers will hold a reference to its parent. The same applies to the origin and category parameters.
Version
1