gpt4 book ai didi

java - 如何检查 Java.util.logging 中启用的信息日志级别

转载 作者:行者123 更新时间:2023-11-30 06:53:25 26 4
gpt4 key购买 nike

如何在实际记录调试语句之前检查是否启用了某个日志记录级别?

最佳答案

是的,它提供了-

Logger#isLoggable(Level level)

Check if a message of the given level would actually be logged by this logger. This check is based on the Loggers effective level, which may be inherited from its parent.

documentation

关于java - 如何检查 Java.util.logging 中启用的信息日志级别,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37612301/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com