public class ConsoleColorLog extends ConsoleLog
| Constructor and Description |
|---|
ConsoleColorLog(Class<?> clazz)
构造
|
ConsoleColorLog(String name)
构造
|
| Modifier and Type | Method and Description |
|---|---|
void |
log(String fqcn,
Level level,
Throwable t,
String format,
Object... arguments)
打印 ERROR 等级的日志
|
static void |
setColorFactory(Function<Level,Ansi4BitColor> colorFactory)
设置颜色工厂,根据日志级别,定义不同的颜色
|
debug, error, getName, info, isDebugEnabled, isEnabled, isErrorEnabled, isInfoEnabled, isTraceEnabled, isWarnEnabled, setLevel, trace, warndebug, debug, debug, error, error, error, info, info, info, log, log, trace, trace, trace, warn, warn, warnpublic ConsoleColorLog(String name)
name - 类名public ConsoleColorLog(Class<?> clazz)
clazz - 类public static void setColorFactory(Function<Level,Ansi4BitColor> colorFactory)
colorFactory - 颜色工厂函数public void log(String fqcn, Level level, Throwable t, String format, Object... arguments)
Loglog in interface Loglog in class ConsoleLogfqcn - 完全限定类名(Fully Qualified Class Name),用于定位日志位置level - 级别t - 错误对象format - 消息模板arguments - 参数Copyright © 2025. All rights reserved.