Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef ApproxMVBB_Common_LogDefines_hpp
00011 #define ApproxMVBB_Common_LogDefines_hpp
00012
00013 #include <iostream>
00014
00015 #include "ApproxMVBB/Config/Config.hpp"
00016
00017 #define ApproxMVBB_LOG(message ) { std::cout << message ; }
00018 #define ApproxMVBB_LOGLEVEL(level,setlevel,message) { if( level <= setlevel ){ ApproxMVBB_LOG(message); } }
00019 #define ApproxMVBB_LOGLEVEL_SCOPE(level) { if( level <= setlevel ) { }
00020 #define ApproxMVBB_LOGLEVEL_SCOPE_END { } }
00021
00022
00023 #if ApproxMVBB_FORCE_MSGLOG_LEVEL > 0
00024 #define ApproxMVBB_MSGLOG_LEVEL ApproxMVBB_FORCE_MSGLOG_LEVEL // force the output level if set in the config!
00025 #else
00026 #ifndef NDEBUG
00027
00028 #define ApproxMVBB_MSGLOG_LEVEL 2 // 0 = no output
00029 #else
00030 #define ApproxMVBB_MSGLOG_LEVEL 0 // 0 = no output
00031 #endif
00032 #endif
00033
00034 #define ApproxMVBB_MSGLOG_L1(message ) { ApproxMVBB_LOGLEVEL(1, ApproxMVBB_MSGLOG_LEVEL, message) }
00035 #define ApproxMVBB_MSGLOG_L2(message ) { ApproxMVBB_LOGLEVEL(2, ApproxMVBB_MSGLOG_LEVEL, message) }
00036 #define ApproxMVBB_MSGLOG_L3(message ) { ApproxMVBB_LOGLEVEL(3, ApproxMVBB_MSGLOG_LEVEL, message) }
00037
00038
00039 #endif