CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
CPUSpender Class Reference
Inheritance diagram for CPUSpender:
edm::stream::EDAnalyzer<> edm::stream::EDAnalyzerBase edm::EDConsumerBase

Public Member Functions

void analyze (const edm::Event &event, const edm::EventSetup &eventSetup) override
 
void beginJob ()
 
 CPUSpender (const edm::ParameterSet &pset)
 Constructor. More...
 
void endJob ()
 
 ~CPUSpender () override
 Destructor. More...
 
- Public Member Functions inherited from edm::stream::EDAnalyzer<>
 EDAnalyzer ()=default
 
- Public Member Functions inherited from edm::stream::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
 ~EDAnalyzerBase () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Attributes

unsigned int timePerEvent_
 

Additional Inherited Members

- Public Types inherited from edm::stream::EDAnalyzer<>
typedef CacheContexts< T... > CacheTypes
 
typedef CacheTypes::GlobalCache GlobalCache
 
typedef AbilityChecker< T... > HasAbility
 
typedef CacheTypes::LuminosityBlockCache LuminosityBlockCache
 
typedef LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCacheLuminosityBlockContext
 
typedef CacheTypes::LuminosityBlockSummaryCache LuminosityBlockSummaryCache
 
typedef CacheTypes::RunCache RunCache
 
typedef RunContextT< RunCache, GlobalCacheRunContext
 
typedef CacheTypes::RunSummaryCache RunSummaryCache
 
- Public Types inherited from edm::stream::EDAnalyzerBase
typedef EDAnalyzerAdaptorBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::stream::EDAnalyzerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

Definition at line 7 of file CPUSpender.cc.

Constructor & Destructor Documentation

CPUSpender::CPUSpender ( const edm::ParameterSet pset)
inline

Constructor.

Definition at line 10 of file CPUSpender.cc.

References edm::ParameterSet::getUntrackedParameter(), and timePerEvent_.

10 { timePerEvent_ = pset.getUntrackedParameter<int>("secPerEvent"); }
unsigned int timePerEvent_
Definition: CPUSpender.cc:30
T getUntrackedParameter(std::string const &, T const &) const
CPUSpender::~CPUSpender ( )
inlineoverride

Destructor.

Definition at line 13 of file CPUSpender.cc.

13 {}

Member Function Documentation

void CPUSpender::analyze ( const edm::Event event,
const edm::EventSetup eventSetup 
)
inlineoverride

Definition at line 15 of file CPUSpender.cc.

References alignCSCRings::s, ntuplemaker::time, and timePerEvent_.

15  {
16  time_t s = time(nullptr);
17  while (time(nullptr) - s < timePerEvent_) {
18  continue;
19  }
20  }
unsigned int timePerEvent_
Definition: CPUSpender.cc:30
void CPUSpender::beginJob ( void  )
inline

Definition at line 23 of file CPUSpender.cc.

23 {}
void CPUSpender::endJob ( void  )
inline

Definition at line 24 of file CPUSpender.cc.

Referenced by o2olib.O2ORunMgr::executeJob().

24 {}

Member Data Documentation

unsigned int CPUSpender::timePerEvent_
private

Definition at line 30 of file CPUSpender.cc.

Referenced by analyze(), and CPUSpender().