日志管理添加不同类型日志的显示开关方法

This commit is contained in:
dgflash
2022-08-13 09:45:32 +08:00
parent 5b1b6a5e80
commit 0e23ba67b0

View File

@@ -38,6 +38,15 @@ export class Logger {
LogType.Trace;
}
/**
* 设置显示的日志类型,默认值为不显示任何类型日志
* @example
* oops.log.setTag(LogType.View|LogType.Business)
*/
static setTag(tag: LogType = 0) {
this.tags = tag;
}
/**
* 记录开始计时
* @param describe 标题描述