Go to the documentation of this file.
30 #ifndef __NMV_LOG_STREAM_H__
31 #define __NMV_LOG_STREAM_H__
38 #ifndef NMV_DEFAULT_DOMAIN
39 #define NMV_DEFAULT_DOMAIN __extension__ \
41 const char* path = __FILE__; \
42 Glib::path_get_basename (path); \
46 #ifndef NMV_GENERAL_DOMAIN
47 #define NMV_GENERAL_DOMAIN "general-domain"
91 static void set_stream_type (
enum StreamType a_type);
95 static enum StreamType get_stream_type ();
103 static void set_stream_file_path (
const char* a_file_path,
long a_len=-1);
108 static const char* get_stream_file_path ();
118 static void set_log_level_filter (
enum LogLevel a_level);
126 static void set_log_domain_filter (
const char* a_domain,
long a_len=-1);
130 static void activate (
bool a_activate);
134 static bool is_active ();
150 LogStream (
enum LogLevel a_level=LOG_LEVEL_NORMAL,
160 void enable_domain (
const string &a_domain,
161 bool a_do_enable=
true);
164 bool is_domain_enabled (
const string &a_domain);
178 LogStream& write (
const Glib::ustring &a_msg,
195 void push_domain (
const string &a_domain);
262 #endif //__NMV_LOG_STREAM_H__
Stream & operator<<(Stream &a_os, const Address &a)
Definition: nmv-address.h:61
Definition: nmv-address.h:31
@ RFU0
Definition: nmv-log-stream.h:77
#define NEMIVER_API
Definition: nmv-api-macros.h:53
LogLevel
Definition: nmv-log-stream.h:82
@ RFU2
Definition: nmv-log-stream.h:79
LogStream & flush(LogStream &)
flushes the stream Use it like: nemiver::LogStream out; out << "Hello" << nemiver::flush;
LogStream & level_normal(LogStream &)
sets the log level to normal Use it like nemiver::LogStream out; out << nemiver::level_normal << "bla...
LogStream & endl(LogStream &)
log a '\n' and flushes the stream Use it like: nemiver::LogStream out; out << "hello"<< nemiver::endl...
StreamType
Definition: nmv-log-stream.h:73
the log stream class it features logs on cout, cerr, and files. it also features log domains and log ...
Definition: nmv-log-stream.h:57
@ RFU1
Definition: nmv-log-stream.h:78
#define NMV_GENERAL_DOMAIN
Definition: nmv-log-stream.h:47
LogStream & timestamp(LogStream &)
logs a timestamp. Basically the the current date. You use it like: nemiver::LogStream out; out << nem...
LogStream & level_verbose(LogStream &)
sets the log level to verbose Use it lik: nemiver::LogStream out; out << nemiver::level_verbose << "b...
Definition: nmv-proc-list-dialog.h:32