77 info() <<
"listing all unchecked return codes:" <<
endmsg;
84 debug() <<
"all StatusCode instances where checked" <<
endmsg;
110 if (fnc ==
"_PyObject_GC_Malloc")
return;
112 if (fnc ==
"PyThread_get_thread_ident")
return;
113 if (fnc ==
"local")
return;
116 const string rlib = lib.
substr(lib.
rfind(
"/") + 1);
125 fatal() <<
"Unchecked StatusCode in " << fnc <<
" from lib "
130 string key = fnc + lib;
132 auto itr =
m_dat.find(key);
134 if (itr !=
m_dat.end()) {
135 itr->second.count += 1;
138 const string rlib = lib.substr(lib.rfind(
"/") + 1);
158 os <<
"Num | Function | Source Library" <<
endl;
159 os <<
"----+--------------------------------+-------------------"
160 <<
"-----------------------" << endl;
162 for(
const auto& itr :
m_dat) {
163 const auto& dat = itr.second;
166 os.
setf(ios_base::right,ios_base::adjustfield);
171 os.
setf(ios_base::left,ios_base::adjustfield);
175 os.
setf(ios_base::left,ios_base::adjustfield);
193 return d.second.fnc == str;
205 return d.second.lib == str;
216 auto loc = str.
find(
"=");
217 if (loc == std::string::npos) {
221 string key = str.
substr(0,loc);
222 string val = str.
substr(loc+1);
226 if (key ==
"FCN" || key ==
"FNC") {
229 }
else if (key ==
"LIB") {
236 warning() <<
"ignoring unknown token in Filter: " << str
StatusCode initialize() override
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
Gaudi::StateMachine::State m_state
Service state.
MsgStream & info() const
shortcut for the method msgStream(MSG::INFO)
StatusCode reinitialize() override
bool isSuccess() const
Test for a status code of SUCCESS.
void list() const override
std::map< std::string, StatCodeDat > m_dat
BooleanProperty m_suppress
#define DECLARE_COMPONENT(type)
void parseFilter(const std::string &str, std::string &fnc, std::string &lib)
StatusCode initialize() override
MsgStream & warning() const
shortcut for the method msgStream(MSG::WARNING)
This class is used for returning status codes from appropriate routines.
std::set< std::string > m_filterfnc
const TYPE & value() const
explicit conversion
void regFnc(const std::string &func, const std::string &lib) override
StringArrayProperty m_pFilter
MsgStream & debug() const
shortcut for the method msgStream(MSG::DEBUG)
StatusCodeSvc(const std::string &name, ISvcLocator *svc)
void filterLib(const std::string &)
MsgStream & fatal() const
shortcut for the method msgStream(MSG::FATAL)
Property * declareProperty(const std::string &name, T &property, const std::string &doc="none") const
Declare the named property.
MSG::Level msgLevel() const
get the output level from the embedded MsgStream
void toupper(std::string &s)
MsgStream & endmsg(MsgStream &s)
MsgStream Modifier: endmsg. Calls the output method of the MsgStream.
void filterFnc(const std::string &)
StatusCode finalize() override
std::set< std::string > m_filterlib