@Test
public void testLoggerLoaction() {
String loggerBinderClassName = "org.slf4j.impl.StaticLoggerBinder";
Class<?> loggerBinderClass = null;
try {
loggerBinderClass = Class.forName(loggerBinderClassName);
} catch (ClassNotFoundException e) {
System.out.println(loggerBinderClassName + " is not found");
}
URL loaction = loggerBinderClass.getProtectionDomain().getCodeSource().getLocation();
System.out.println(loaction);
}
判断使用的日志框架
乱蜂朝王2023-12-30 17:15
相关推荐
大可不必了2 小时前
03 函数定义和调用I_belong_to_jesus2 小时前
C++关于分支预测的优化1承渊政道3 小时前
【Python编程—从入门到实践】(记分与闯关:用Python+Pygame,打造越战越精彩的太空大战!)爱学习的程序媛3 小时前
Python常用框架梳理budingxiaomoli4 小时前
Spring统一功能处理eggwyw5 小时前
Anaconda安装卸载的详细流程指南Flynn Liang6 小时前
可观测性与成本治理:一次对话的 17 个观测点金銀銅鐵6 小时前
带您看懂字节码指令(三):同一行加法,为什么有四种指令another heaven9 小时前
【C/C++ Ranges 是零开销抽象吗?拆开管道、惰性求值和编译期膨胀】文丑颜不良啊10 小时前
LeetCode2821~2840题目解析