@bitdiver/logadapter-dispatcher
Advanced tools
Comparing version 1.0.2 to 1.0.3
@@ -27,3 +27,39 @@ "use strict"; | ||
} | ||
/** | ||
* sets a new log level | ||
* @param level {number/string} The logLevel as number or String value | ||
*/ | ||
set level(level) { | ||
if (this.logAdapterList !== undefined && this.logAdapterList.length > 0) { | ||
for (const logger of this.logAdapterList) { | ||
logger.level = level; | ||
} | ||
} | ||
} | ||
/** | ||
* Returns the logLevel as a string | ||
* @return level {string} The logLevel | ||
*/ | ||
get level() { | ||
if (this.logAdapterList !== undefined && this.logAdapterList.length > 0) { | ||
return this.logAdapterList[0].level; | ||
} | ||
} | ||
/** | ||
* Returns the logLevel as a number | ||
* | ||
* @return level {string} The logLevel | ||
*/ | ||
get levelNumber() { | ||
if (this.logAdapterList !== undefined && this.logAdapterList.length > 0) { | ||
return this.logAdapterList[0].levelNumber; | ||
} | ||
} | ||
reset() { | ||
@@ -30,0 +66,0 @@ if (this.logAdapterList !== undefined && this.logAdapterList.length > 0) { |
{ | ||
"name": "@bitdiver/logadapter-dispatcher", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
11901
160