CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Attributes
edm::AnalyzerWrapper< T > Class Template Reference

#include <EDAnalyzerWrapper.h>

Inheritance diagram for edm::AnalyzerWrapper< T >:
edm::EDAnalyzer edm::EDConsumerBase

Public Member Functions

void analyze (edm::Event const &event, const edm::EventSetup &eventSetup) override
 everything which has to be done during the event loop. NOTE: We can't use the eventSetup in FWLite so ignore it More...
 
 AnalyzerWrapper (const edm::ParameterSet &cfg)
 default contructor More...
 
void beginJob () override
 everything which has to be done before the event loop More...
 
void endJob () override
 everything which has to be done after the event loop More...
 
 ~AnalyzerWrapper () override
 default destructor More...
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
 ~EDAnalyzer () 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 &&)=default
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (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::array< std::vector< ModuleDescription const * > *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
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)
 

Protected Attributes

std::shared_ptr< Tanalyzer_
 shared pointer to analysis class of type BasicAnalyzer More...
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
static bool wantsGlobalLuminosityBlocks ()
 
static bool wantsGlobalRuns ()
 
static bool wantsInputProcessBlocks ()
 
static bool wantsProcessBlocks ()
 
static bool wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
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<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 

Detailed Description

template<class T>
class edm::AnalyzerWrapper< T >

Definition at line 44 of file EDAnalyzerWrapper.h.

Constructor & Destructor Documentation

◆ AnalyzerWrapper()

template<class T >
edm::AnalyzerWrapper< T >::AnalyzerWrapper ( const edm::ParameterSet cfg)

default contructor

Definition at line 64 of file EDAnalyzerWrapper.h.

64  {
65  // defined TFileService
66  edm::Service<TFileService> fileService;
67  // create analysis class of type BasicAnalyzer
68  analyzer_ = std::shared_ptr<T>(new T(cfg, fileService->tFileDirectory(), consumesCollector()));
69  }

References looper::cfg, and TFileService::tFileDirectory().

◆ ~AnalyzerWrapper()

template<class T >
edm::AnalyzerWrapper< T >::~AnalyzerWrapper ( )
inlineoverride

default destructor

Definition at line 49 of file EDAnalyzerWrapper.h.

49 {};

Member Function Documentation

◆ analyze()

template<class T >
void edm::AnalyzerWrapper< T >::analyze ( edm::Event const &  event,
const edm::EventSetup eventSetup 
)
inlineoverridevirtual

everything which has to be done during the event loop. NOTE: We can't use the eventSetup in FWLite so ignore it

Implements edm::EDAnalyzer.

Definition at line 53 of file EDAnalyzerWrapper.h.

53 { analyzer_->analyze(event); }

References edm::AnalyzerWrapper< T >::analyzer_.

◆ beginJob()

template<class T >
void edm::AnalyzerWrapper< T >::beginJob ( void  )
inlineoverridevirtual

everything which has to be done before the event loop

Reimplemented from edm::EDAnalyzer.

Definition at line 51 of file EDAnalyzerWrapper.h.

51 { analyzer_->beginJob(); }

References edm::AnalyzerWrapper< T >::analyzer_.

◆ endJob()

template<class T >
void edm::AnalyzerWrapper< T >::endJob ( void  )
inlineoverridevirtual

everything which has to be done after the event loop

Reimplemented from edm::EDAnalyzer.

Definition at line 55 of file EDAnalyzerWrapper.h.

55 { analyzer_->endJob(); }

References edm::AnalyzerWrapper< T >::analyzer_.

Member Data Documentation

◆ analyzer_

template<class T >
std::shared_ptr<T> edm::AnalyzerWrapper< T >::analyzer_
protected

shared pointer to analysis class of type BasicAnalyzer

Definition at line 59 of file EDAnalyzerWrapper.h.

Referenced by edm::AnalyzerWrapper< T >::analyze(), edm::AnalyzerWrapper< T >::beginJob(), and edm::AnalyzerWrapper< T >::endJob().

TFileService::tFileDirectory
TFileDirectory & tFileDirectory()
Definition: TFileService.h:42
edm::EDConsumerBase::consumesCollector
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
Definition: EDConsumerBase.cc:47
edm::AnalyzerWrapper::analyzer_
std::shared_ptr< T > analyzer_
shared pointer to analysis class of type BasicAnalyzer
Definition: EDAnalyzerWrapper.h:59
edm::Service< TFileService >
looper.cfg
cfg
Definition: looper.py:297
T
long double T
Definition: Basic3DVectorLD.h:48
event
Definition: event.py:1