Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有谁知道如何让企业库日志记录消息写入位置的文件名和行号?我正在使用 4.1 版。
如果我理解正确,您可能对 stackframe 类感兴趣。您希望在调用日志记录代码的文件中构建您的消息以获得正确的信息。
StackFrame 类