Gaudi Framework, version v25r0

Home   Generated: Mon Feb 17 2014
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
IssueSeverity.cpp
Go to the documentation of this file.
1 #define GAUDIKERNEL_ISSUESEVERITY_CPP 1
2 
6 #include "GaudiKernel/System.h"
9 
10 #include <sstream>
11 
12 bool IssueSeverity::m_init(false);
14 
16  if (!m_init) {
17  m_init = true;
18  m_ers = Gaudi::svcLocator()->service<IIssueLogger>("IssueLogger").get();
19  }
20 }
21 
23 
24  if (!m_reported) {
25  report();
26  // do stuff
27  }
28 
29 }
30 
31 void
33 
34  if (m_ers != 0) {
35  m_ers->report(this);
36  } else {
37  std::cerr << *this << std::endl;
38  }
39  m_reported = true;
40 
41 }
42 
43 
47  ost << m_file << ":" << m_line;
48  return ost.str();
49 }
50 
51 IssueSeverity::operator StatusCode() const {
52  if (m_level == IssueSeverity::RECOVERABLE) {
53  return StatusCode(StatusCode::RECOVERABLE, *this);
54  } else if (m_level < IssueSeverity::ERROR) {
55  return StatusCode(StatusCode::SUCCESS, *this);
56  } else {
57  return StatusCode(StatusCode::FAILURE, *this);
58  }
59 }

Generated at Mon Feb 17 2014 14:37:45 for Gaudi Framework, version v25r0 by Doxygen version 1.8.2 written by Dimitri van Heesch, © 1997-2004