CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Attributes
edm::ModuleDescription Class Reference

#include <ModuleDescription.h>

Public Member Functions

unsigned int id () const
 
ParameterSetID const & mainParameterSetID () const
 
 ModuleDescription ()
 
 ModuleDescription (ParameterSetID const &pid, std::string const &modName, std::string const &modLabel)
 
 ModuleDescription (ParameterSetID const &pid, std::string const &modName, std::string const &modLabel, ProcessConfiguration const *procConfig, unsigned int modID)
 
 ModuleDescription (std::string const &modName, std::string const &modLabel)
 
 ModuleDescription (std::string const &modName, std::string const &modLabel, ProcessConfiguration const *procConfig)
 
std::string const & moduleLabel () const
 
std::string const & moduleName () const
 
bool operator!= (ModuleDescription const &rh) const
 
bool operator< (ModuleDescription const &rh) const
 
bool operator== (ModuleDescription const &rh) const
 
ParameterSetID const & parameterSetID () const
 
std::string const & passID () const
 
ProcessConfiguration const & processConfiguration () const
 
std::string const & processName () const
 
std::string const & releaseVersion () const
 
void write (std::ostream &os) const
 
 ~ModuleDescription ()
 

Static Public Member Functions

static unsigned int getUniqueID ()
 Returns a unique id each time called. Intended to be passed to ModuleDescription's constructor's modID argument. Thread safe. More...
 
static constexpr unsigned int invalidID ()
 Returns a value identifying an invalid id (the max unsigned int value) More...
 

Private Attributes

unsigned int id_
 
std::string moduleLabel_
 
std::string moduleName_
 
ParameterSetID parameterSetID_
 
ProcessConfiguration const * processConfigurationPtr_
 

Detailed Description

Definition at line 21 of file ModuleDescription.h.

Constructor & Destructor Documentation

◆ ModuleDescription() [1/5]

edm::ModuleDescription::ModuleDescription ( )

Definition at line 16 of file ModuleDescription.cc.

◆ ModuleDescription() [2/5]

edm::ModuleDescription::ModuleDescription ( std::string const &  modName,
std::string const &  modLabel 
)

Definition at line 35 of file ModuleDescription.cc.

36  : ModuleDescription{ParameterSetID(), modName, modLabel, nullptr, invalidID()} {}

References invalidID().

◆ ModuleDescription() [3/5]

edm::ModuleDescription::ModuleDescription ( std::string const &  modName,
std::string const &  modLabel,
ProcessConfiguration const *  procConfig 
)

Definition at line 38 of file ModuleDescription.cc.

41  : ModuleDescription{ParameterSetID(), modName, modLabel, procConfig, invalidID()} {}

References invalidID().

◆ ModuleDescription() [4/5]

edm::ModuleDescription::ModuleDescription ( ParameterSetID const &  pid,
std::string const &  modName,
std::string const &  modLabel 
)

Definition at line 19 of file ModuleDescription.cc.

22  : ModuleDescription{pid, modName, modLabel, nullptr, invalidID()} {}

References invalidID().

◆ ModuleDescription() [5/5]

edm::ModuleDescription::ModuleDescription ( ParameterSetID const &  pid,
std::string const &  modName,
std::string const &  modLabel,
ProcessConfiguration const *  procConfig,
unsigned int  modID 
)

Definition at line 24 of file ModuleDescription.cc.

29  : parameterSetID_(pid),
30  moduleName_(modName),
31  moduleLabel_(modLabel),
32  processConfigurationPtr_(procConfig),
33  id_(iID) {}

◆ ~ModuleDescription()

edm::ModuleDescription::~ModuleDescription ( )

Definition at line 43 of file ModuleDescription.cc.

43 {}

Member Function Documentation

◆ getUniqueID()

unsigned int edm::ModuleDescription::getUniqueID ( )
static

Returns a unique id each time called. Intended to be passed to ModuleDescription's constructor's modID argument. Thread safe.

Definition at line 87 of file ModuleDescription.cc.

87 { return s_id++; }

References s_id.

Referenced by edm::Maker::createModuleDescription(), and edm::makeInput().

◆ id()

unsigned int edm::ModuleDescription::id ( ) const
inline

A unique ID for a module declared in the Process. The id is only unique for the Process and not across different Processes. If the id is invalid, will return the max unsigned int value.

Definition at line 46 of file ModuleDescription.h.

46 { return id_; }

References id_.

Referenced by DQMOneEDAnalyzer< edm::LuminosityBlockCache< alcabeammonitor::NoCache > >::accumulate(), DQMOneLumiEDAnalyzer<>::beginLuminosityBlock(), DQMOneEDAnalyzer< edm::LuminosityBlockCache< alcabeammonitor::NoCache > >::beginRun(), FastTimerService::PlotsPerJob::book(), DQMOneLumiEDAnalyzer<>::endLuminosityBlockProduce(), DQMOneEDAnalyzer< edm::LuminosityBlockCache< alcabeammonitor::NoCache > >::endRunProduce(), edm::service::RandomNumberGeneratorService::getEngine(), DQMGlobalEDAnalyzerBase< dtsegment2dsl::Histograms, Args... >::meId(), edm::SystemTimeKeeper::pauseModuleEvent(), edm::service::Tracer::postEventReadFromSource(), edm::service::SimpleMemoryCheck::postModule(), edm::service::Tracer::postModuleAccessInputProcessBlock(), edm::service::Tracer::postModuleBeginProcessBlock(), NVProfilerService::postModuleBeginStream(), edm::service::Tracer::postModuleEndProcessBlock(), NVProfilerService::postModuleEndStream(), edm::service::Tracer::postModuleEvent(), FastTimerService::postModuleEvent(), NVProfilerService::postModuleEvent(), FastTimerService::postModuleEventAcquire(), edm::service::Tracer::postModuleEventAcquire(), NVProfilerService::postModuleEventAcquire(), edm::service::Tracer::postModuleEventDelayedGet(), edm::service::Tracer::postModuleEventPrefetching(), NVProfilerService::postModuleEventPrefetching(), edm::service::Tracer::postModuleGlobalBeginLumi(), NVProfilerService::postModuleGlobalBeginLumi(), edm::service::Tracer::postModuleGlobalBeginRun(), NVProfilerService::postModuleGlobalBeginRun(), edm::service::Tracer::postModuleGlobalEndLumi(), NVProfilerService::postModuleGlobalEndLumi(), edm::service::Tracer::postModuleGlobalEndRun(), NVProfilerService::postModuleGlobalEndRun(), edm::service::Tracer::postModuleStreamBeginLumi(), NVProfilerService::postModuleStreamBeginLumi(), edm::service::Tracer::postModuleStreamBeginRun(), NVProfilerService::postModuleStreamBeginRun(), edm::service::RandomNumberGeneratorService::postModuleStreamCheck(), edm::service::Tracer::postModuleStreamEndLumi(), NVProfilerService::postModuleStreamEndLumi(), edm::service::Tracer::postModuleStreamEndRun(), NVProfilerService::postModuleStreamEndRun(), edm::service::Tracer::postModuleWriteLumi(), edm::service::Tracer::postModuleWriteProcessBlock(), edm::service::Tracer::postModuleWriteRun(), FastTimerService::postSourceEvent(), ProcessCallGraph::preBeginJob(), edm::service::Tracer::preEventReadFromSource(), edm::service::SimpleMemoryCheck::preModule(), edm::service::Tracer::preModuleAccessInputProcessBlock(), edm::service::Tracer::preModuleBeginProcessBlock(), NVProfilerService::preModuleBeginStream(), edm::service::StallMonitor::preModuleConstruction(), edm::service::StallMonitor::preModuleDestruction(), edm::service::Tracer::preModuleEndProcessBlock(), NVProfilerService::preModuleEndStream(), edm::service::Tracer::preModuleEvent(), NVProfilerService::preModuleEvent(), edm::service::Tracer::preModuleEventAcquire(), NVProfilerService::preModuleEventAcquire(), edm::service::Tracer::preModuleEventDelayedGet(), edm::service::Tracer::preModuleEventPrefetching(), NVProfilerService::preModuleEventPrefetching(), edm::service::Tracer::preModuleGlobalBeginLumi(), NVProfilerService::preModuleGlobalBeginLumi(), edm::service::Tracer::preModuleGlobalBeginRun(), NVProfilerService::preModuleGlobalBeginRun(), edm::service::Tracer::preModuleGlobalEndLumi(), NVProfilerService::preModuleGlobalEndLumi(), edm::service::Tracer::preModuleGlobalEndRun(), NVProfilerService::preModuleGlobalEndRun(), edm::service::Tracer::preModuleStreamBeginLumi(), NVProfilerService::preModuleStreamBeginLumi(), edm::service::Tracer::preModuleStreamBeginRun(), NVProfilerService::preModuleStreamBeginRun(), edm::service::RandomNumberGeneratorService::preModuleStreamCheck(), edm::service::Tracer::preModuleStreamEndLumi(), NVProfilerService::preModuleStreamEndLumi(), edm::service::Tracer::preModuleStreamEndRun(), NVProfilerService::preModuleStreamEndRun(), edm::service::Tracer::preModuleWriteLumi(), edm::service::Tracer::preModuleWriteProcessBlock(), edm::service::Tracer::preModuleWriteRun(), DependencyGraph::preSourceConstruction(), ProcessCallGraph::preSourceConstruction(), edm::SystemTimeKeeper::restartModuleEvent(), edm::SystemTimeKeeper::startModuleEvent(), edm::SystemTimeKeeper::stopModuleEvent(), and edm::service::ConcurrentModuleTimer::trackModule().

◆ invalidID()

static constexpr unsigned int edm::ModuleDescription::invalidID ( )
inlinestaticconstexpr

Returns a value identifying an invalid id (the max unsigned int value)

Definition at line 66 of file ModuleDescription.h.

References SiStripPI::max.

Referenced by ModuleDescription().

◆ mainParameterSetID()

ParameterSetID const & edm::ModuleDescription::mainParameterSetID ( ) const

◆ moduleLabel()

std::string const& edm::ModuleDescription::moduleLabel ( ) const
inline

Definition at line 43 of file ModuleDescription.h.

43 { return moduleLabel_; }

References moduleLabel_.

Referenced by edm::ProductRegistryHelper::addToRegistry(), edm::ScheduleInfo::availableModuleLabels(), edm::PuttableSourceBase::beginJob(), edm::Worker::beginJob(), evf::EvFOutputModule::beginRun(), edm::Worker::beginStream(), ExternalGeneratorFilter::beginStream(), FastTimerService::PlotsPerJob::book(), FastTimerService::encodeToJSON(), edm::Worker::endJob(), edm::Worker::endStream(), edm::Worker::exceptionContext(), edm::PrincipalGetAdapter::getBranchDescription(), edm::service::RandomNumberGeneratorService::getEngine(), HLTFilter::moduleLabel(), HLTStreamFilter::moduleLabel(), HLTHighLevel::moduleLabel(), edm::service::RandomNumberGeneratorService::mySeed(), operator<(), edm::ScheduleInfo::parametersForModule(), TriggerResultsFilterFromDB::pathsFromSetup(), edm::service::Tracer::postEventReadFromSource(), edm::service::SimpleMemoryCheck::postModule(), edm::service::Tracer::postModuleAccessInputProcessBlock(), edm::service::SimpleMemoryCheck::postModuleBeginJob(), edm::service::Tracer::postModuleBeginProcessBlock(), CUDAMonitoringService::postModuleBeginStream(), edm::service::SimpleMemoryCheck::postModuleConstruction(), edm::service::Tracer::postModuleEndProcessBlock(), CUDAMonitoringService::postModuleEvent(), edm::service::Tracer::postModuleEvent(), edm::service::Tracer::postModuleEventAcquire(), edm::service::Tracer::postModuleEventDelayedGet(), edm::service::Tracer::postModuleEventPrefetching(), edm::service::Tracer::postModuleGlobalBeginLumi(), edm::service::Tracer::postModuleGlobalBeginRun(), edm::service::Tracer::postModuleGlobalEndLumi(), edm::service::Tracer::postModuleGlobalEndRun(), edm::service::Tracer::postModuleStreamBeginLumi(), edm::service::Tracer::postModuleStreamBeginRun(), edm::service::RandomNumberGeneratorService::postModuleStreamCheck(), edm::service::Tracer::postModuleStreamEndLumi(), edm::service::Tracer::postModuleStreamEndRun(), edm::service::Tracer::postModuleWriteLumi(), edm::service::Tracer::postModuleWriteProcessBlock(), edm::service::Tracer::postModuleWriteRun(), edm::service::SimpleMemoryCheck::postSourceConstruction(), edm::service::Tracer::preEventReadFromSource(), edm::service::Tracer::preModuleAccessInputProcessBlock(), edm::service::Tracer::preModuleBeginProcessBlock(), NVProfilerService::preModuleBeginStream(), edm::service::StallMonitor::preModuleConstruction(), edm::service::Tracer::preModuleEndProcessBlock(), NVProfilerService::preModuleEndStream(), edm::service::Tracer::preModuleEvent(), NVProfilerService::preModuleEvent(), edm::service::Tracer::preModuleEventAcquire(), NVProfilerService::preModuleEventAcquire(), edm::service::Tracer::preModuleEventDelayedGet(), edm::service::Tracer::preModuleEventPrefetching(), NVProfilerService::preModuleEventPrefetching(), edm::service::Tracer::preModuleGlobalBeginLumi(), NVProfilerService::preModuleGlobalBeginLumi(), edm::service::Tracer::preModuleGlobalBeginRun(), NVProfilerService::preModuleGlobalBeginRun(), edm::service::Tracer::preModuleGlobalEndLumi(), NVProfilerService::preModuleGlobalEndLumi(), edm::service::Tracer::preModuleGlobalEndRun(), NVProfilerService::preModuleGlobalEndRun(), edm::service::Tracer::preModuleStreamBeginLumi(), NVProfilerService::preModuleStreamBeginLumi(), edm::service::Tracer::preModuleStreamBeginRun(), NVProfilerService::preModuleStreamBeginRun(), edm::service::Tracer::preModuleStreamEndLumi(), NVProfilerService::preModuleStreamEndLumi(), edm::service::Tracer::preModuleStreamEndRun(), NVProfilerService::preModuleStreamEndRun(), edm::service::Tracer::preModuleWriteLumi(), edm::service::Tracer::preModuleWriteProcessBlock(), edm::service::Tracer::preModuleWriteRun(), DependencyGraph::preSourceConstruction(), edm::service::SimpleMemoryCheck::preSourceConstruction(), edm::UnscheduledProductResolver::resolveProduct_(), edm::Maker::throwConfigurationException(), edm::PrincipalGetAdapter::throwUnregisteredPutException(), and write().

◆ moduleName()

std::string const& edm::ModuleDescription::moduleName ( ) const
inline

◆ operator!=()

bool edm::ModuleDescription::operator!= ( ModuleDescription const &  rh) const

Definition at line 85 of file ModuleDescription.cc.

85 { return !((*this) == rh); }

◆ operator<()

bool edm::ModuleDescription::operator< ( ModuleDescription const &  rh) const

Definition at line 57 of file ModuleDescription.cc.

57  {
58  if (moduleLabel() < rh.moduleLabel())
59  return true;
60  if (rh.moduleLabel() < moduleLabel())
61  return false;
62  if (processName() < rh.processName())
63  return true;
64  if (rh.processName() < processName())
65  return false;
66  if (moduleName() < rh.moduleName())
67  return true;
68  if (rh.moduleName() < moduleName())
69  return false;
70  if (parameterSetID() < rh.parameterSetID())
71  return true;
72  if (rh.parameterSetID() < parameterSetID())
73  return false;
74  if (releaseVersion() < rh.releaseVersion())
75  return true;
76  if (rh.releaseVersion() < releaseVersion())
77  return false;
78  if (passID() < rh.passID())
79  return true;
80  return false;
81  }

References moduleLabel(), moduleName(), parameterSetID(), passID(), processName(), and releaseVersion().

◆ operator==()

bool edm::ModuleDescription::operator== ( ModuleDescription const &  rh) const

Definition at line 83 of file ModuleDescription.cc.

83 { return !((*this) < rh || rh < (*this)); }

◆ parameterSetID()

ParameterSetID const& edm::ModuleDescription::parameterSetID ( ) const
inline

◆ passID()

std::string const & edm::ModuleDescription::passID ( ) const

Definition at line 51 of file ModuleDescription.cc.

51 { return processConfiguration().passID(); }

References edm::ProcessConfiguration::passID(), and processConfiguration().

Referenced by operator<().

◆ processConfiguration()

ProcessConfiguration const & edm::ModuleDescription::processConfiguration ( ) const

◆ processName()

std::string const & edm::ModuleDescription::processName ( ) const

◆ releaseVersion()

std::string const & edm::ModuleDescription::releaseVersion ( ) const

Definition at line 49 of file ModuleDescription.cc.

References processConfiguration(), and edm::ProcessConfiguration::releaseVersion().

Referenced by operator<().

◆ write()

void edm::ModuleDescription::write ( std::ostream &  os) const

Definition at line 89 of file ModuleDescription.cc.

89  {
90  os << "Module type=" << moduleName() << ", "
91  << "Module label=" << moduleLabel() << ", "
92  << "Parameter Set ID=" << parameterSetID();
93  //<< "Parameter Set ID=" << parameterSetID() << ", "
94  //<< "Process name=" << processName() << ", "
95  //<< "Release Version=" << releaseVersion() << ", "
96  //<< "Pass ID=" << passID() << ", "
97  //<< "Main Parameter Set ID=" << mainParameterSetID();
98  }

References moduleLabel(), moduleName(), and parameterSetID().

Referenced by pkg.AbstractPkg::generate().

Member Data Documentation

◆ id_

unsigned int edm::ModuleDescription::id_
private

Definition at line 82 of file ModuleDescription.h.

Referenced by id().

◆ moduleLabel_

std::string edm::ModuleDescription::moduleLabel_
private

◆ moduleName_

std::string edm::ModuleDescription::moduleName_
private

Definition at line 73 of file ModuleDescription.h.

Referenced by moduleName().

◆ parameterSetID_

ParameterSetID edm::ModuleDescription::parameterSetID_
private

Definition at line 70 of file ModuleDescription.h.

Referenced by parameterSetID().

◆ processConfigurationPtr_

ProcessConfiguration const* edm::ModuleDescription::processConfigurationPtr_
private

Definition at line 80 of file ModuleDescription.h.

Referenced by processConfiguration().

edm::ParameterSetID
Hash< ParameterSetType > ParameterSetID
Definition: ParameterSetID.h:21
edm::ModuleDescription::moduleLabel
std::string const & moduleLabel() const
Definition: ModuleDescription.h:43
edm::ProcessConfiguration::releaseVersion
ReleaseVersion const & releaseVersion() const
Definition: ProcessConfiguration.h:27
edm::ModuleDescription::invalidID
static constexpr unsigned int invalidID()
Returns a value identifying an invalid id (the max unsigned int value)
Definition: ModuleDescription.h:66
s_id
static std::atomic< unsigned int > s_id
Definition: ModuleDescription.cc:8
edm::ModuleDescription::moduleName
std::string const & moduleName() const
Definition: ModuleDescription.h:42
edm::ModuleDescription::processConfigurationPtr_
ProcessConfiguration const * processConfigurationPtr_
Definition: ModuleDescription.h:80
edm::ModuleDescription::processName
std::string const & processName() const
Definition: ModuleDescription.cc:47
edm::ModuleDescription::parameterSetID_
ParameterSetID parameterSetID_
Definition: ModuleDescription.h:70
edm::ProcessConfiguration::passID
PassID const & passID() const
Definition: ProcessConfiguration.h:28
edm::ModuleDescription::processConfiguration
ProcessConfiguration const & processConfiguration() const
Definition: ModuleDescription.cc:45
edm::ProcessConfiguration::processName
std::string const & processName() const
Definition: ProcessConfiguration.h:24
edm::ModuleDescription::moduleLabel_
std::string moduleLabel_
Definition: ModuleDescription.h:77
edm::ProcessConfiguration::parameterSetID
ParameterSetID const & parameterSetID() const
Definition: ProcessConfiguration.cc:31
SiStripPI::max
Definition: SiStripPayloadInspectorHelper.h:169
edm::ModuleDescription::releaseVersion
std::string const & releaseVersion() const
Definition: ModuleDescription.cc:49
edm::ModuleDescription::id_
unsigned int id_
Definition: ModuleDescription.h:82
edm::ModuleDescription::ModuleDescription
ModuleDescription()
Definition: ModuleDescription.cc:16
edm::ModuleDescription::moduleName_
std::string moduleName_
Definition: ModuleDescription.h:73
edm::ModuleDescription::parameterSetID
ParameterSetID const & parameterSetID() const
Definition: ModuleDescription.h:41
edm::ModuleDescription::passID
std::string const & passID() const
Definition: ModuleDescription.cc:51