Package | Description |
---|---|
org.dromara.hutool.log |
Hutool-log只是一个日志的通用门面,功能类似于Slf4j。
|
org.dromara.hutool.log.engine |
第三方日志库的实现封装
|
org.dromara.hutool.log.engine.commons |
Apache-Commons-Logging日志库的实现封装
|
org.dromara.hutool.log.engine.console |
控制台输出的实现封装
|
org.dromara.hutool.log.engine.jboss |
jboss-logging实现
|
org.dromara.hutool.log.engine.jdk |
JDK-Logging的实现封装
|
org.dromara.hutool.log.engine.log4j |
Log4j的实现封装
|
org.dromara.hutool.log.engine.log4j2 |
Log4j2的实现封装
|
org.dromara.hutool.log.engine.slf4j |
Slf4j的实现封装
|
org.dromara.hutool.log.engine.tinylog |
tinylog的实现封装
封装包括TinyLog和TinyLog2 |
Modifier and Type | Class and Description |
---|---|
class |
AbsLogEngine
抽象日期引擎
提供保存日志框架名称和checkLogExist方法 |
Modifier and Type | Method and Description |
---|---|
static LogEngine |
LogEngineFactory.createEngine()
决定日志实现
依次按照顺序检查日志库的jar是否被引入,如果未引入任何日志库,则检查ClassPath下的logging.properties,
存在则使用JdkLogFactory,否则使用ConsoleLogFactory |
static LogEngine |
LogEngineFactory.createEngine(Class<? extends LogEngine> logEngineClass)
创建指定日志实现引擎
|
static LogEngine |
LogEngineFactory.getEngine()
根据用户引入的模板引擎jar,自动创建对应的模板引擎对象
获得的是单例的TemplateEngine |
Modifier and Type | Method and Description |
---|---|
static void |
LogEngineFactory.setDefaultEngine(LogEngine logEngine)
自定义日志实现
|
Modifier and Type | Method and Description |
---|---|
static LogEngine |
LogEngineFactory.createEngine(Class<? extends LogEngine> logEngineClass)
创建指定日志实现引擎
|
static void |
LogEngineFactory.setDefaultEngine(Class<? extends LogEngine> logEngineClass)
自定义默认日志实现
|
Modifier and Type | Class and Description |
---|---|
class |
ApacheCommonsLogEngine
Apache Commons Logging
|
Modifier and Type | Class and Description |
---|---|
class |
ConsoleColorLogEngine
利用System.out.println()打印彩色日志
|
class |
ConsoleLogEngine
利用System.out.println()打印日志
|
Modifier and Type | Class and Description |
---|---|
class |
JbossLogEngine
Jboss-Logging log.
|
Modifier and Type | Class and Description |
---|---|
class |
JdkLogEngine
JDK日志工厂类
java.util.logging log.
|
Modifier and Type | Class and Description |
---|---|
class |
Log4jLogEngine
Apache Log4J log.
|
Modifier and Type | Class and Description |
---|---|
class |
Log4j2LogEngine
Apache Log4J 2 log.
|
Modifier and Type | Class and Description |
---|---|
class |
Slf4jLogEngine
SLF4J log.
|
Modifier and Type | Class and Description |
---|---|
class |
TinyLog2Engine
TinyLog2 log.
|
class |
TinyLogEngine
TinyLog log.
|
Copyright © 2025. All rights reserved.