CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
BasicAnalyzer Class Reference

Abstract base class for FWLite and EDM friendly analyzers. More...

#include "PhysicsTools/UtilAlgos/interface/BasicAnalyzer.h"

Detailed Description

Abstract base class for FWLite and EDM friendly analyzers.

Abstract base class for FWLite and EDM friendly analyzers. This class provides a proper interface needed for the EDAnalyzerWrapper and FWLiteAnalyzerWrapper template classes. Classes of type BasicAnalyzer can be wrapped into an EDAnalyzer as shown in the example below:

include "PhysicsTools/PatExamples/interface/BasicMuonAnalyzer.h" include "PhysicsTools/UtilAlgos/interface/EDAnalyzerWrapper.h"

typedef edm::AnalyzerWrapper<BasicMuonAnalyzer> WrappedEDAnalyzer;

include "FWCore/Framework/interface/MakerMacros.h" DEFINE_FWK_MODULE(WrappedEDAnalyzer);

Alternatively they can be wrapped into a FWLiteAnalyzer which provides basic functionality of reading configuration files and event looping as shown in the example below:

include "PhysicsTools/PatExamples/interface/BasicMuonAnalyzer.h" include "PhysicsTools/UtilAlgos/interface/FWLiteAnalyzerWrapper.h"

typedef fwlite::AnalyzerWrapper<BasicMuonAnalyzer> WrappedFWLiteAnalyzer; ...

In both examples BasicMuonAnalyzer is derived from the BasicAnalyzer class. For more information have a look into the class description of the corresponding wrapper classes.