68 std::ostream &
operator<<(
const std::string & s ) ;
78 std::ostringstream m_ss ;
91 #define G_LOG_OUTPUT( expr , severity ) do { G::Log(severity,__FILE__,__LINE__) << expr ; } while(0)
92 #if defined(G_WITH_DEBUG) || ( defined(_DEBUG) && ! defined(G_NO_DEBUG) )
93 #define G_DEBUG( expr ) G_LOG_OUTPUT( expr , G::Log::s_Debug )
95 #define G_DEBUG( expr )
97 #if ! defined(G_NO_LOG)
98 #define G_LOG( expr ) G_LOG_OUTPUT( expr , G::Log::s_LogVerbose )
100 #define G_LOG( expr )
102 #if ! defined(G_NO_LOG_S)
103 #define G_LOG_S( expr ) G_LOG_OUTPUT( expr , G::Log::s_LogSummary )
105 #define G_LOG_S( expr )
107 #define G_WARNING( expr ) G_LOG_OUTPUT( expr , G::Log::s_Warning )
108 #define G_ERROR( expr ) G_LOG_OUTPUT( expr , G::Log::s_Error )
A class for adding line number information to the Log output.
Log(Severity, const char *file, int line)
Constructor.
A static class for doing iostream-based logging.
std::ostream & operator<<(const char *s)
Streams 's' and then returns a stream for streaming more stuff into.
Line(const char *file, int line)
~Log()
Destructor. Writes the accumulated string to the log output.