Go to the documentation of this file.
29 #include <boost/call_traits.hpp>
30 #include <boost/ref.hpp>
31 #include <miaconfig.h>
38 #ifndef VSTREAM_DOMAIN
39 #define VSTREAM_DOMAIN "**"
102 bool shows(
Level l)
const;
105 bool show_debug()
const;
121 if (m_message_level >= m_output_level)
144 operator std::ostream& ()
150 vstream(std::ostream& output, Level l);
152 static std::ostream *m_output_target;
153 static __thread std::ostream *m_output;
154 Level m_output_level;
155 static __thread Level m_message_level;
178 return l >= m_output_level;
190 << m_fill <<
"enter " << m_domain <<
"\n";
196 << m_fill <<
"leave " << m_domain <<
"\n";
200 const char *m_domain;
203 static __thread
size_t m_depth;
207 #ifndef ENABLE_DEBUG_MESSAGES
208 #define TRACE(DOMAIN)
209 #define TRACE_FUNCTION
210 #define FUNCTION_NOT_TESTED
247 #define TRACE(DOMAIN) ::mia::CTrace _xxx_trace(DOMAIN)
250 #define TRACE_FUNCTION ::mia::CTrace _xxx_trace(__PRETTY_FUNCTION__)
253 #define FUNCTION_NOT_TESTED ::mia::cvwarn() << __PRETTY_FUNCTION__ << ":not tested\n"
277 return m_output_level;
341 #define cverb ::mia::vstream::instance()
std::ostream & operator<<(std::ostream &os, const CAttribute &attr)
CDebugSink & operator<<(std::ostream &(*)(std::ostream &))
vstream & cvinfo()
informal output that may be of interest to understand problems with a program and are of higher prior...
static vstream & instance()
void set_verbose(bool verbose)
#define NS_MIA_BEGIN
conveniance define to start the mia namespace
A output stream to enable certain levels of verbosity.
vstream & cvfatal()
direct output to this stream adapter to print out fatalities in the code
#define NS_MIA_END
conveniance define to end the mia namespace
vstream & operator<<(std::ostream &(*f)(std::ostream &))
std::ostream & set_stream(std::ostream &os)
void set_verbosity(Level l)
vstream & cvwarn()
send warnings to this stream adapter
CDebugSink & operator<<(const T &val)
EXPORT_CORE const TDictMap< vstream::Level > g_verbose_dict
Dictonary for the verbosity of the logging as used by –verbose comand line option.
A mapper from emums to string values. - usefull for names flags.
vstream & cvmsg()
send messages to this stream adapter
#define EXPORT_CORE
Macro to manage Visual C++ style dllimport/dllexport.
vstream::Level get_level() const
vstream & cvfail()
direct output to this stream adapter to print out failtures in tests beyond BOOST_FAIL
bool shows(Level l) const
void flush()
write pending output
CTrace(const char *domain)
static void set_output_target(std::ostream *os)
vstream & cverr()
send errors to this stream adapter