CocoaLumberjack+YOHO.h 1.51 KB
//
//  CocoaLumberjack+YOHO.h
//  LoggerDemo
//
//  Created by gaoqiang xu on 07/06/2017.
//  Copyright © 2017 SealedCompany. All rights reserved.
//

#ifndef CocoaLumberjack_YOHO_h
#define CocoaLumberjack_YOHO_h

#import "DDLog+YOHO.h"

/*
 *  tag: 可以任何自定义信息,比如开发者信息
 *  这个信息会打印到log file里
*/

#define YOHOLogError(tag, frmt, ...)                     \
      [DDLog logWithFunctionName:__FUNCTION__            \
                            line:__LINE__                \
                      loggerUser:tag                     \
                    errorMessage:frmt, ## __VA_ARGS__]

#define YOHOLogWarn(tag, frmt, ...)                      \
      [DDLog logWithFunctionName:__FUNCTION__            \
                            line:__LINE__                \
                      loggerUser:tag                    \
                     warnMessage:frmt, ## __VA_ARGS__]

#define YOHOLogDebug(tag, frmt, ...)                     \
      [DDLog logWithFunctionName:__FUNCTION__            \
                            line:__LINE__                \
                      loggerUser:tag                    \
                    debugMessage:frmt, ## __VA_ARGS__]

#define YOHOLogInfo(tag, frmt, ...)                      \
      [DDLog logWithFunctionName:__FUNCTION__            \
                            line:__LINE__                \
                      loggerUser:tag                    \
                     infoMessage:frmt, ## __VA_ARGS__]

#endif /* CocoaLumberjack_YOHO_h */