日志记录类
More...
#include <slog.h>
|
| Log (const char *tag, int level, const char *filename, const char *funcname, int lineIndex, void *pAddr) |
| 构造函数
|
|
| ~Log () |
| 析构函数
|
|
SLogStream & | stream () |
| 获取日志流对象
|
|
日志记录类
Definition at line 151 of file slog.h.
◆ anonymous enum
Enumerator |
---|
MAX_TAGLEN | 最大标签长度
|
MAX_LOGLEN | 最大日志长度
|
Definition at line 153 of file slog.h.
◆ Log()
Log::Log |
( |
const char * | tag, |
|
|
int | level, |
|
|
const char * | filename, |
|
|
const char * | funcname, |
|
|
int | lineIndex, |
|
|
void * | pAddr ) |
构造函数
- Parameters
-
tag | 日志标签 |
level | 日志级别 |
filename | 文件名 |
funcname | 函数名 |
lineIndex | 行号 |
pAddr | 返回地址 |
Definition at line 46 of file slog.cpp.
◆ ~Log()
◆ setLogCallback()
void Log::setLogCallback |
( |
LogCallback | logCallback | ) |
|
|
static |
设置日志回调函数
- Parameters
-
Definition at line 95 of file slog.cpp.
◆ setLogEcho()
void Log::setLogEcho |
( |
bool | bEnable | ) |
|
|
static |
设置日志回显功能
- Parameters
-
Definition at line 100 of file slog.cpp.
◆ setLogLevel()
void Log::setLogLevel |
( |
int | nLevel | ) |
|
|
static |
设置日志级别
- Parameters
-
Definition at line 88 of file slog.cpp.
◆ stream()
获取日志流对象
- Returns
- 日志流对象引用
Definition at line 83 of file slog.cpp.
The documentation for this class was generated from the following files: