CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ModuleDescription.cc
Go to the documentation of this file.
2 
3 #include <ostream>
4 #include <sstream>
5 
6 /*----------------------------------------------------------------------
7 
8 ----------------------------------------------------------------------*/
9 
10 namespace edm {
11 
13  parameterSetID_(),
14  moduleName_(),
15  moduleLabel_(),
16  processConfigurationPtr_(nullptr) {}
17 
19  ParameterSetID const& pid,
20  std::string const& modName,
21  std::string const& modLabel) : ModuleDescription{pid, modName, modLabel, nullptr} {}
22 
24  ParameterSetID const& pid,
25  std::string const& modName,
26  std::string const& modLabel,
27  ProcessConfiguration const* procConfig) :
28  parameterSetID_(pid),
29  moduleName_(modName),
30  moduleLabel_(modLabel),
31  processConfigurationPtr_(procConfig) {}
32 
34  std::string const& modName,
35  std::string const& modLabel) : ModuleDescription{ParameterSetID(), modName, modLabel, nullptr} {}
36 
38  std::string const& modName,
39  std::string const& modLabel,
40  ProcessConfiguration const* procConfig) : ModuleDescription{ParameterSetID(), modName, modLabel, procConfig} {}
41 
43 
47  }
48 
51  return processConfiguration().id();
52  }
53 
54  std::string const&
57  }
58 
59  std::string const&
62  }
63 
64  std::string const&
66  return processConfiguration().passID();
67  }
68 
69  ParameterSetID const&
72  }
73 
74  bool
76  if (moduleLabel() < rh.moduleLabel()) return true;
77  if (rh.moduleLabel() < moduleLabel()) return false;
78  if (processName() < rh.processName()) return true;
79  if (rh.processName() < processName()) return false;
80  if (moduleName() < rh.moduleName()) return true;
81  if (rh.moduleName() < moduleName()) return false;
82  if (parameterSetID() < rh.parameterSetID()) return true;
83  if (rh.parameterSetID() < parameterSetID()) return false;
84  if (releaseVersion() < rh.releaseVersion()) return true;
85  if (rh.releaseVersion() < releaseVersion()) return false;
86  if (passID() < rh.passID()) return true;
87  return false;
88  }
89 
90  bool
92  return !((*this) < rh || rh < (*this));
93  }
94 
95  bool
97  return !((*this) == rh);
98  }
99 
100  void
101  ModuleDescription::write(std::ostream& os) const {
102  os << "Module type=" << moduleName() << ", "
103  << "Module label=" << moduleLabel() << ", "
104  << "Parameter Set ID=" << parameterSetID();
105  //<< "Parameter Set ID=" << parameterSetID() << ", "
106  //<< "Process name=" << processName() << ", "
107  //<< "Release Version=" << releaseVersion() << ", "
108  //<< "Pass ID=" << passID() << ", "
109  //<< "Main Parameter Set ID=" << mainParameterSetID();
110  }
111 }
ParameterSetID const & mainParameterSetID() const
std::string const & processName() const
ProcessConfigurationID id() const
#define nullptr
std::string const & moduleName() const
std::string const & passID() const
std::string const & moduleLabel() const
PassID const & passID() const
ProcessConfiguration const * processConfigurationPtr_
std::string const & processName() const
ParameterSetID const & parameterSetID() const
std::string const & releaseVersion() const
bool operator!=(ModuleDescription const &rh) const
bool operator==(ModuleDescription const &rh) const
ProcessConfigurationID processConfigurationID() const
Hash< ParameterSetType > ParameterSetID
ReleaseVersion const & releaseVersion() const
ParameterSetID const & parameterSetID() const
void write(std::ostream &os) const
ProcessConfiguration const & processConfiguration() const
bool operator<(ModuleDescription const &rh) const