UNPKG

typescript-logging

Version:

Library for logging, written in typescript, can be used by normal es5+ javascript as well.

46 lines 1.49 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); /** * Options object you can use to configure the LoggerFactory you create at LFService. */ var LoggerFactoryOptions = (function () { function LoggerFactoryOptions() { this._logGroupRules = []; this._enabled = true; } /** * Add LogGroupRule, see {LogGroupRule) for details * @param rule Rule to add * @returns {LoggerFactoryOptions} returns itself */ LoggerFactoryOptions.prototype.addLogGroupRule = function (rule) { this._logGroupRules.push(rule); return this; }; /** * Enable or disable logging completely for the LoggerFactory. * @param enabled True for enabled (default) * @returns {LoggerFactoryOptions} returns itself */ LoggerFactoryOptions.prototype.setEnabled = function (enabled) { this._enabled = enabled; return this; }; Object.defineProperty(LoggerFactoryOptions.prototype, "logGroupRules", { get: function () { return this._logGroupRules; }, enumerable: true, configurable: true }); Object.defineProperty(LoggerFactoryOptions.prototype, "enabled", { get: function () { return this._enabled; }, enumerable: true, configurable: true }); return LoggerFactoryOptions; }()); exports.LoggerFactoryOptions = LoggerFactoryOptions; //# sourceMappingURL=LoggerFactoryOptions.js.map