fw4spl
log.hpp
1 /* ***** BEGIN LICENSE BLOCK *****
2  * FW4SPL - Copyright (C) IRCAD, 2009-2015.
3  * Distributed under the terms of the GNU Lesser General Public License (LGPL) as
4  * published by the Free Software Foundation.
5  * ****** END LICENSE BLOCK ****** */
6 
7 #ifndef __FWATOMSPATCH_INFOS_LOG_HPP__
8 #define __FWATOMSPATCH_INFOS_LOG_HPP__
9 
10 #include "fwAtomsPatch/infos/Logger.hpp"
11 
13 # ifdef _DEBUG
14 
15 # define fwAtomsPatchInfoLogMacro(message) \
16  ::fwAtomsPatch::infos::Logger::getLogger().info(message)
17 
18 # define fwAtomsPatchErrorLogMacro(message) \
19  ::fwAtomsPatch::infos::Logger::getLogger().error(message)
20 
21 # define fwAtomsPatchBadCastLogMacro(message) \
22  ::fwAtomsPatch::infos::Logger::getLogger().badCast(message)
23 
24 # define fwAtomsPatchOutOfRangeLogMacro(message) \
25  ::fwAtomsPatch::infos::Logger::getLogger().outOfRange(message)
26 
27 # define fwAtomsPatchAddAttributeLogMacro(message) \
28  ::fwAtomsPatch::infos::Logger::getLogger().addAttribute(message)
29 
30 # define fwAtomsPatchEraseAttributeLogMacro(message) \
31  ::fwAtomsPatch::infos::Logger::getLogger().eraseAttribute(message)
32 
33 # define fwAtomsPatchReplaceAttributeLogMacro(message) \
34  ::fwAtomsPatch::infos::Logger::getLogger().replaceAttribute(message)
35 # else
36 
37 # define fwAtomsPatchInfoLogMacro(message) // nothing
38 
39 # define fwAtomsPatchErrorLogMacro(message) // nothing
40 
41 # define fwAtomsPatchBadCastLogMacro(message) // nothing
42 
43 # define fwAtomsPatchOutOfRangeLogMacro(message) // nothing
44 
45 # define fwAtomsPatchAddAttributeLogMacro(message) // nothing
46 
47 # define fwAtomsPatchEraseAttributeLogMacro(message) // nothing
48 
49 # define fwAtomsPatchReplaceAttributeLogMacro(message) // nothing
50 # endif
51 
53 #endif // __FWATOMSPATCH_INFOS_LOG_HPP__