The Gaudi Framework
v30r3 (a5ef0a68)
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
IMessageSvc.h
Go to the documentation of this file.
1
#ifndef GAUDIKERNEL_IMESSAGESVC_H
2
#define GAUDIKERNEL_IMESSAGESVC_H
3
4
// Include files
5
#include "
GaudiKernel/IInterface.h
"
6
#include <iostream>
7
#include <string>
8
9
// Forward declarations
10
class
StatusCode
;
11
class
Message
;
12
14
namespace
MSG
15
{
16
enum
Level
{
NIL
= 0,
VERBOSE
,
DEBUG
,
INFO
,
WARNING
,
ERROR
,
FATAL
,
ALWAYS
,
NUM_LEVELS
};
17
enum
Color
{
BLACK
= 0,
RED
,
GREEN
,
YELLOW
,
BLUE
,
PURPLE
,
CYAN
,
WHITE
,
NUM_COLORS
};
18
}
19
20
#ifdef _WIN32
21
// Avoid (hopefully) conflicts between Windows' headers and MSG.
22
#ifndef NOMSG
23
#define NOMSG
24
#ifndef NOGDI
25
#define NOGDI
26
#endif
27
#endif
28
#endif
29
38
class
GAUDI_API
IMessageSvc
:
virtual
public
IInterface
39
{
40
public
:
42
DeclareInterfaceID
(
IMessageSvc
, 2, 0 );
43
48
virtual
void
reportMessage(
const
Message
&
msg
,
int
outputLevel ) = 0;
49
53
virtual
void
reportMessage(
const
Message
& message ) = 0;
54
60
virtual
void
reportMessage(
const
StatusCode
& code,
const
std::string
& source =
""
) = 0;
61
67
virtual
void
reportMessage(
const
std::string
& source,
int
type
,
const
std::string
& message ) = 0;
68
75
virtual
void
reportMessage(
const
char
* source,
int
type,
const
char
* message =
""
) = 0;
76
81
virtual
void
insertMessage(
const
StatusCode
& code,
const
Message
& message ) = 0;
82
84
virtual
void
eraseMessage() = 0;
85
87
virtual
void
eraseMessage(
const
StatusCode
& code ) = 0;
88
93
virtual
void
eraseMessage(
const
StatusCode
& code,
const
Message
& message ) = 0;
94
100
virtual
void
insertStream(
int
type,
const
std::string
&
name
,
std::ostream
* stream ) = 0;
101
103
virtual
void
eraseStream() = 0;
104
106
virtual
void
eraseStream(
int
message_type ) = 0;
107
112
virtual
void
eraseStream(
int
type,
std::ostream
* stream ) = 0;
113
117
virtual
void
eraseStream(
std::ostream
* stream ) = 0;
118
120
virtual
std::ostream
* defaultStream()
const
= 0;
121
125
virtual
void
setDefaultStream(
std::ostream
* stream ) = 0;
126
128
virtual
int
outputLevel()
const
= 0;
129
133
virtual
int
outputLevel(
const
std::string
& source )
const
= 0;
134
136
virtual
void
setOutputLevel(
int
new_level ) = 0;
137
142
virtual
void
setOutputLevel(
const
std::string
& source,
int
new_level ) = 0;
143
146
virtual
bool
useColor()
const
= 0;
147
151
virtual
std::string
getLogColor(
int
logLevel )
const
= 0;
152
155
virtual
int
messageCount(
MSG::Level
level
)
const
= 0;
156
};
157
158
class
GAUDI_API
IInactiveMessageCounter
:
virtual
public
IInterface
159
{
160
public
:
162
DeclareInterfaceID
(
IInactiveMessageCounter
, 1, 0 );
163
168
virtual
void
incrInactiveCount(
MSG::Level
level
,
const
std::string
& src ) = 0;
169
};
170
171
#endif // GAUDIKERNEL_IMESSAGESVC_H
gaudiComponentHelp.name
name
Definition:
gaudiComponentHelp.py:32
MSG::CYAN
Definition:
IMessageSvc.h:17
MSG::GREEN
Definition:
IMessageSvc.h:17
MSG::DEBUG
Definition:
IMessageSvc.h:16
IInactiveMessageCounter
Definition:
IMessageSvc.h:158
MSG::VERBOSE
Definition:
IMessageSvc.h:16
MSG::WHITE
Definition:
IMessageSvc.h:17
std::string
STL class.
MSG::FATAL
Definition:
IMessageSvc.h:16
MSG::Level
Level
Definition:
IMessageSvc.h:16
MSG::RED
Definition:
IMessageSvc.h:17
MSG::BLUE
Definition:
IMessageSvc.h:17
StatusCode
This class is used for returning status codes from appropriate routines.
Definition:
StatusCode.h:51
DeclareInterfaceID
#define DeclareInterfaceID(iface, major, minor)
Macro to declare the interface ID when using the new mechanism of extending and implementing interfac...
Definition:
IInterface.h:13
IInterface
Definition of the basic interface.
Definition:
IInterface.h:277
gaudirun.type
type
Definition:
gaudirun.py:133
IMessageSvc
The IMessage is the interface implemented by the message service.
Definition:
IMessageSvc.h:38
MSG::NUM_COLORS
Definition:
IMessageSvc.h:17
MSG::NIL
Definition:
IMessageSvc.h:16
Message
The Message class.
Definition:
Message.h:15
MSG::NUM_LEVELS
Definition:
IMessageSvc.h:16
MSG
Print levels enumeration.
Definition:
IMessageSvc.h:14
MSG::BLACK
Definition:
IMessageSvc.h:17
GaudiMP.FdsRegistry.msg
msg
Definition:
FdsRegistry.py:8
MSG::ERROR
Definition:
IMessageSvc.h:16
MSG::PURPLE
Definition:
IMessageSvc.h:17
gaudirun.level
level
Definition:
gaudirun.py:271
MSG::WARNING
Definition:
IMessageSvc.h:16
MSG::INFO
Definition:
IMessageSvc.h:16
GAUDI_API
#define GAUDI_API
Definition:
Kernel.h:104
IInterface.h
MSG::YELLOW
Definition:
IMessageSvc.h:17
std::ostream
STL class.
MSG::ALWAYS
Definition:
IMessageSvc.h:16
MSG::Color
Color
Definition:
IMessageSvc.h:17
GaudiKernel
GaudiKernel
IMessageSvc.h
Generated on Wed Aug 1 2018 23:21:03 for The Gaudi Framework by
1.8.11