CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_4_5_patch3/src/SimGeneral/MixingModule/plugins/MixingModule.h

Go to the documentation of this file.
00001 #ifndef MixingModule_h
00002 #define MixingModule_h
00003 
00017 #include "Mixing/Base/interface/BMixingModule.h"
00018 
00019 #include "FWCore/Framework/interface/Event.h"
00020 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00021 #include "FWCore/Utilities/interface/InputTag.h"
00022 #include "FWCore/Framework/interface/Selector.h"
00023 
00024 #include "SimDataFormats/CrossingFrame/interface/CrossingFrame.h"
00025 #include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h"
00026 #include "SimDataFormats/CaloHit/interface/PCaloHitContainer.h"
00027 #include "SimDataFormats/Track/interface/SimTrackContainer.h"
00028 #include "SimDataFormats/Vertex/interface/SimVertexContainer.h"
00029 #include "SimDataFormats/GeneratorProducts/interface/HepMCProduct.h"
00030 #include "SimDataFormats/PileupSummaryInfo/interface/PileupMixingContent.h"
00031 
00032 #include "DataFormats/Provenance/interface/ProductID.h"
00033 #include "DataFormats/Common/interface/Handle.h"
00034 
00035 #include "MixingWorkerBase.h"
00036 
00037 #include <vector>
00038 #include <string>
00039 
00040 class CrossingFramePlaybackInfoExtended;
00041 class MixingWorkerBase;
00042 namespace edm
00043 {
00044   class MixingModule : public BMixingModule
00045     {
00046     public:
00047 
00049       explicit MixingModule(const edm::ParameterSet& ps);
00050 
00052       virtual ~MixingModule();
00053 
00054       virtual void beginJob() {}
00055  
00056     private:
00057       virtual void branchesActivate(const std::string &friendlyName, const std::string &subdet, InputTag &tag, std::string &label);
00058       virtual void put(edm::Event &e,const edm::EventSetup& es);
00059       virtual void createnewEDProduct();
00060       virtual void checkSignal(const edm::Event &e);
00061       virtual void addSignals(const edm::Event &e, const edm::EventSetup& es); 
00062       virtual void doPileUp(edm::Event &e, const edm::EventSetup& es);
00063       //      void pileAllWorkers(EventPrincipal const& ep, int bcr, int& id, int& offset);
00064       void pileAllWorkers(EventPrincipal const& ep, int bcr, int id, int& offset);
00065       std::string labelPlayback_;
00066       bool mixProdStep2_;
00067       bool mixProdStep1_;
00068       CrossingFramePlaybackInfoExtended *playbackInfo_;
00069 
00070       Selector * sel_;
00071 
00072       std::vector<MixingWorkerBase *> workers_;
00073       std::vector<MixingWorkerBase *> workersObjects_;
00074       std::vector<std::string> wantedBranches_;
00075       bool useCurrentProcessOnly_;
00076     };
00077 }//edm
00078 
00079 #endif