5 #include <Core/CFDefines.h> 8 #define CFLOGI(...) cf_log_Common(TAG, CFLOGLV_INFO, __VA_ARGS__); 9 #define CFLOGD(...) cf_log_Common(TAG, CFLOGLV_DEBUG, __VA_ARGS__); 10 #define CFLOGW(...) cf_log_Common(TAG, CFLOGLV_WARNING, __VA_ARGS__); 11 #define CFLOGE(...) cf_log_Common(TAG, CFLOGLV_ERROR, __VA_ARGS__); 12 #define CFLOGF(...) cf_log_Common(TAG, CFLOGLV_FATAL, __VA_ARGS__); 14 CF_EXPORT
void cf_enable_debug();
15 CF_EXPORT
void cf_disable_debug();
16 CF_EXPORT
void cf_enable_info();
17 CF_EXPORT
void cf_disable_info();
19 CF_EXPORT
void cf_log_Common(
const char* logtag,
CFLogLevel level,
const char* format, ...);
66 static void i(
const char* tag,
const char* format, ...);
80 static void d(
const char* tag,
const char* format, ...);
92 static void w(
const char* tag,
const char* format, ...);
104 static void e(
const char* tag,
const char* format, ...);
116 static void f(
const char* tag,
const char* format, ...);
134 static CFLog* getInst();
136 void log(
CFLogLevel level,
const char* tag,
const char* format, va_list ap);
138 void addMask(
unsigned int mask);
139 void removeMask(
unsigned int mask);
141 char* currentTimeStr();
144 static CFLog* s_inst;
148 #endif // __CF_LOG_H__ static void e(const char *tag, const char *format,...)
输出CFLOGLV_ERROR级别日志
static void logCommon(CFLogLevel level, const char *tag, const char *format, va_list ap)
输出日志信息
CFLogLevel
日志级别枚举类型
Definition: CFTypes.h:26
static void addLevelMask(unsigned int mask)
增加log输出的级别。
static void i(const char *tag, const char *format,...)
输出CFLOGLV_INFO级别日志
static void w(const char *tag, const char *format,...)
输出CFLOGLV_WARNING级别日志
static void d(const char *tag, const char *format,...)
输出CFLOGLV_DEBUG级别日志
CFLog 类.
Definition: CFLog.h:28
static void f(const char *tag, const char *format,...)
输出CFLOGLV_FATAL级别日志
static void removeLevelMask(unsigned int mask)
关闭log输出的级别。