Go to the documentation of this file.
28 #define KERNEL_MSGSTREAM_CPP
54 m_inactCounter = svc ? Gaudi::Cast<IInactiveMessageCounter>( svc ) : 0;
63 m_inactCounter = svc ? Gaudi::Cast<IInactiveMessageCounter>( svc ) : 0;
120 const int buffsize = 2048;
121 static char buffer[buffsize];
123 va_start( arguments,
fmt );
124 if ( vsnprintf( buffer, buffsize,
fmt, arguments ) >= buffsize ) {
std::string format(const char *fmt,...)
MsgStream format utility "a la sprintf(...)".
static GAUDI_API bool enableCountInactive(bool value=true)
Enable/disable the count of inactive messages.
IMessageSvc * m_service
Pointer to message service if buffer has send.
virtual std::string getLogColor(int logLevel) const =0
Get the color codes for various log levels.
bool m_useColors
use colors
virtual GAUDI_API MsgStream & doOutput()
Output method.
GAUDI_API void setColor(MSG::Color col)
Set the text color.
MSG::Level m_level
Debug level of the message service.
virtual bool useColor() const =0
Show whether colors are used.
virtual void reportMessage(const Message &msg, int outputLevel)=0
Report a message by sending a Message object to the message service.
virtual int outputLevel() const =0
Retrieve the current output level threshold.
std::ostringstream m_stream
String MsgStream associated to buffer.
std::string m_source
Use std::string for source information to be passed to the message service.
MSG::Level m_currLevel
Current debug level.
GAUDI_API MsgStream(IMessageSvc *svc, int buffer_length=128)
Standard constructor: Connect to message service for output.
constexpr static const auto FAILURE
void setLevel(int level)
Update outputlevel.
IInactiveMessageCounter * m_inactCounter
Pointer to service counting messages prepared but not printed because of wrong level.
bool isActive() const
Accessor: is MsgStream active.
GAUDI_API void resetColor()
Reset the colors to defaults.
static bool m_countInactive
Flag to state if the inactive messages has to be counted.
static GAUDI_API bool countInactive()
Returns the state of the counting of inactive messages (enabled/disabled).