dl
类 | 命名空间 | 宏定义 | 函数 | 变量
dl_log.h 文件参考

日志系统 更多...

#include <string>
#include <iostream>
#include <stack>
#include <array>
#include "system/dl_platform.h"
#include <stacktrace>
#include <source_location>
#include <fmt/format.h>

浏览源代码.

类

class  dl::LogSystem
 
struct  dl::LogSystem::Setting
 
class  dl::LogLimit
 

命名空间

namespace  dl
 

宏定义

#define log_(...)   log(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_pause(...)   log_pause0(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_test(...)   log_test0(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_info(...)   log_info0(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_msg(...)   log_msg0(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_notice(...)   log_notice0(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_warn(...)   log_warn0(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_err(...)   log_err0(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_damage(...)   log_damage0(fmt::format(__VA_ARGS__), std::source_location::current())
 
#define log_(...)   log(fmt::format(__VA_ARGS__))
 
#define log_pause(...)   log_pause0(fmt::format(__VA_ARGS__))
 
#define log_test(...)   log_test0(fmt::format(__VA_ARGS__))
 
#define log_info(...)   log_info0(fmt::format(__VA_ARGS__))
 
#define log_msg(...)   log_msg0(fmt::format(__VA_ARGS__))
 
#define log_notice(...)   log_notice0(fmt::format(__VA_ARGS__))
 
#define log_warn(...)   log_warn0(fmt::format(__VA_ARGS__))
 
#define log_err(...)   log_err0(fmt::format(__VA_ARGS__))
 
#define log_damage(...)   log_damage0(fmt::format(__VA_ARGS__))
 

函数

void dl::log_easy (std::string_view str)
 输出日志 更多...
 
void dl::log_pause0 (std::string_view str, const std::source_location location=std::source_location::current())
 
void dl::log_test0 (std::string_view str, const std::source_location location=std::source_location::current())
 
void dl::log_info0 (std::string_view str, const std::source_location location=std::source_location::current())
 
void dl::log_msg0 (std::string_view str, const std::source_location location=std::source_location::current())
 
void dl::log_notice0 (std::string_view str, const std::source_location location=std::source_location::current())
 
void dl::log_warn0 (std::string_view str, const std::source_location location=std::source_location::current())
 
void dl::log_err0 (std::string_view str, const std::source_location location=std::source_location::current())
 
void dl::log_damage0 (std::string_view str, const std::source_location location=std::source_location::current())
 
void dl::log (std::string_view str, const std::source_location location=std::source_location::current())
 以当前设置输出 更多...
 
void dl::log_err0 (const std::exception &e, const std::source_location location=std::source_location::current())
 
void dl::log (std::string_view str)
 
void dl::log_pause0 (std::string_view str)
 
void dl::log_test0 (std::string_view str)
 
void dl::log_info0 (std::string_view str)
 
void dl::log_msg0 (std::string_view str)
 
void dl::log_notice0 (std::string_view str)
 
void dl::log_warn0 (std::string_view str)
 
void dl::log_err0 (std::string_view str)
 
void dl::log_damage0 (std::string_view str)
 
void dl::log_err0 (const std::exception &e)
 

变量

constexpr std::array< std::string_view, 9 > dl::DL_LOG_SYSTEM_LEVLE_NAME
 
LogSystem * dl::g_log
 

详细描述

日志系统

版本
1.0
作者
lveyou
日期
23-06-22
注解

在文件 dl_log.h 中定义.

宏定义说明

◆ log_ [1/2]

#define log_ (   ...)    log(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 189 行定义.

◆ log_ [2/2]

#define log_ (   ...)    log(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 189 行定义.

◆ log_damage [1/2]

#define log_damage (   ...)    log_damage0(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 197 行定义.

◆ log_damage [2/2]

#define log_damage (   ...)    log_damage0(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 197 行定义.

◆ log_err [1/2]

#define log_err (   ...)    log_err0(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 196 行定义.

◆ log_err [2/2]

#define log_err (   ...)    log_err0(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 196 行定义.

◆ log_info [1/2]

#define log_info (   ...)    log_info0(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 192 行定义.

◆ log_info [2/2]

#define log_info (   ...)    log_info0(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 192 行定义.

◆ log_msg [1/2]

#define log_msg (   ...)    log_msg0(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 193 行定义.

◆ log_msg [2/2]

#define log_msg (   ...)    log_msg0(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 193 行定义.

◆ log_notice [1/2]

#define log_notice (   ...)    log_notice0(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 194 行定义.

◆ log_notice [2/2]

#define log_notice (   ...)    log_notice0(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 194 行定义.

◆ log_pause [1/2]

#define log_pause (   ...)    log_pause0(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 190 行定义.

◆ log_pause [2/2]

#define log_pause (   ...)    log_pause0(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 190 行定义.

◆ log_test [1/2]

#define log_test (   ...)    log_test0(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 191 行定义.

◆ log_test [2/2]

#define log_test (   ...)    log_test0(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 191 行定义.

◆ log_warn [1/2]

#define log_warn (   ...)    log_warn0(fmt::format(__VA_ARGS__), std::source_location::current())

在文件 dl_log.h 第 195 行定义.

◆ log_warn [2/2]

#define log_warn (   ...)    log_warn0(fmt::format(__VA_ARGS__))

在文件 dl_log.h 第 195 行定义.