Created
September 17, 2014 06:51
-
-
Save jesusdomin/7bd3066a715f7bfc0820 to your computer and use it in GitHub Desktop.
LogUtil
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* LogUtil.h | |
*/ | |
// Comment for hide | |
#define LOG_INFO | |
#define LOG_ERROR | |
#define LOG_DEBUG | |
//#define LOG_FINE_DEBUG | |
#ifdef LOG_INFO | |
# define ILog(fmt, ...) NSLog((@"INFO%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); | |
#else | |
# define ILog(...) | |
#endif | |
#ifdef LOG_ERROR | |
# define ELog(fmt, ...) NSLog((@"ERROR%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); | |
#else | |
# define ELog(...) | |
#endif | |
#ifdef LOG_DEBUG | |
# define DLog(fmt, ...) NSLog((@"DEBUG%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); | |
#else | |
# define DLog(...) | |
#endif | |
#ifdef LOG_FINE_DEBUG | |
# define FLog(fmt, ...) NSLog((@"FINE%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); | |
#else | |
# define FLog(...) | |
#endif | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment