DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
ValidationReport.hpp
Go to the documentation of this file.
1
8
9#ifndef APPFWK_INCLUDE_APPFWK_VALIDATIONREPORT_HPP_
10#define APPFWK_INCLUDE_APPFWK_VALIDATIONREPORT_HPP_
11
12#include <string>
13
14namespace dunedaq {
15
16namespace appfwk {
17
19{
20public:
29
30 ValidationReport(Severity sev, std::string app, std::string module, std::string command, std::string message)
31 : m_severity(sev)
32 , m_app(app)
33 , m_module(module)
34 , m_command(command)
35 , m_message(message)
36 {
37 }
38
39 std::string severity_string()
40 {
41 switch (m_severity) {
42 case Severity::Fatal:
43 return "Fatal";
44 case Severity::Error:
45 return "Error";
47 return "Warning";
48 case Severity::Info:
49 return "Info";
51 return "Debug";
52 }
53 return "UNKNOWN";
54 }
55
56 Severity get_severity() const { return m_severity; }
57 std::string get_app() const { return m_app; }
58 std::string get_module() const { return m_module; }
59 std::string get_command() const { return m_command; }
60 std::string get_message() const { return m_message; }
61
62private:
64 std::string m_app;
65 std::string m_module;
66 std::string m_command;
67 std::string m_message;
68};
69
70} // namespace appfwk
71} // namespace dunedaq
72
73#endif // APPFWK_INCLUDE_APPFWK_VALIDATIONREPORT_HPP_
ValidationReport(Severity sev, std::string app, std::string module, std::string command, std::string message)
The DUNE-DAQ namespace.