Files
XCEngine/docs/api/debug/logger/warning.md

705 B

Logger::Warning

void Warning(LogCategory category, const Containers::String& message);

记录 Warning 级别日志。用于记录警告信息,表示可能存在问题但程序仍能继续运行。

参数:

  • category - 日志分类
  • message - 日志消息内容

返回:

线程安全:

示例:

#include "XCEngine/Debug/Logger.h"

using namespace XCEngine::Debug;

Logger& logger = Logger::Get();
logger.Warning(LogCategory::Memory, "High memory usage detected");
logger.Warning(LogCategory::Rendering, "Low GPU memory");

相关文档