LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
ModuleType.h
Go to the documentation of this file.
1 #ifndef art_Persistency_Provenance_ModuleType_h
2 #define art_Persistency_Provenance_ModuleType_h
3 // vim: set sw=2 expandtab :
4 
6 
7 #include <string>
8 
9 namespace art {
10 
11  enum class ModuleType {
12  non_art,
13  producer,
14  filter,
15  analyzer,
18  };
20 
21  inline bool
23  {
24  return (mt == ModuleType::producer) || (mt == ModuleType::filter);
25  }
26 
27  inline bool
29  {
30  return (mt == ModuleType::analyzer) || (mt == ModuleType::output_module);
31  }
32 
33  inline std::string
35  {
36  switch (mt) {
38  return "non-art";
40  return "producer";
41  case ModuleType::filter:
42  return "filter";
44  return "analyzer";
46  return "output module";
47  default:
49  << "Unable to find string for unrecognized ModuleType value "
50  << static_cast<int>(mt) << ".\n";
51  }
52  }
53 
54 } // namespace art
55 
56 #endif /* art_Persistency_Provenance_ModuleType_h */
57 
58 // Local Variables:
59 // mode: c++
60 // End:
bool is_modifier(ModuleType const mt)
Definition: ModuleType.h:22
cet::coded_exception< errors::ErrorCodes, ExceptionDetail::translate > Exception
Definition: Exception.h:66
ModuleThreadingType
Definition: ModuleType.h:19
Definition: MVAAlg.h:12
bool is_observer(ModuleType const mt)
Definition: ModuleType.h:28
std::string to_string(ModuleType const mt)
Definition: ModuleType.h:34
ModuleType
Definition: ModuleType.h:11