CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_1_8_patch9/src/RecoLocalTracker/SiPixelClusterizer/interface/SiPixelClusterProducer.h

Go to the documentation of this file.
00001 #ifndef RecoLocalTracker_SiPixelClusterizer_SiPixelClusterProducer_h
00002 #define RecoLocalTracker_SiPixelClusterizer_SiPixelClusterProducer_h
00003 
00004 //---------------------------------------------------------------------------
00029 //---------------------------------------------------------------------------
00030 
00031 #include "RecoLocalTracker/SiPixelClusterizer/interface/PixelClusterizerBase.h"
00032 
00033 //#include "Geometry/CommonDetUnit/interface/TrackingGeometry.h"
00034 
00035 #include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h"
00036 
00037 #include "DataFormats/Common/interface/DetSetVector.h"
00038 #include "DataFormats/Common/interface/DetSetVectorNew.h"
00039 #include "DataFormats/SiPixelDigi/interface/PixelDigi.h"
00040 #include "DataFormats/SiPixelCluster/interface/SiPixelCluster.h"
00041 #include "DataFormats/Common/interface/EDProduct.h"
00042 
00043 
00044 #include "FWCore/Framework/interface/EDProducer.h"
00045 #include "FWCore/Framework/interface/Event.h"
00046 #include "FWCore/Framework/interface/EventSetup.h"
00047 #include "DataFormats/Common/interface/Handle.h"
00048 #include "FWCore/Framework/interface/ESHandle.h"
00049 
00050 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00051 #include "FWCore/Utilities/interface/InputTag.h"
00052 
00053 
00054 
00055 namespace cms
00056 {
00057 
00058   class SiPixelClusterProducer : public edm::EDProducer {
00059   public:
00060     //--- Constructor, virtual destructor (just in case)
00061     explicit SiPixelClusterProducer(const edm::ParameterSet& conf);
00062     virtual ~SiPixelClusterProducer();
00063 
00064     void setupClusterizer();
00065 
00066     // Begin Job
00067     //virtual void beginJob( const edm::EventSetup& );
00068     virtual void beginJob( );
00069 
00070     //--- The top-level event method.
00071     virtual void produce(edm::Event& e, const edm::EventSetup& c);
00072 
00073     //--- Execute the algorithm(s).
00074     void run(const edm::DetSetVector<PixelDigi>   & input,
00075              edm::ESHandle<TrackerGeometry>       & geom,
00076              edmNew::DetSetVector<SiPixelCluster> & output);
00077 
00078   private:
00079     edm::ParameterSet conf_;
00080     // TO DO: maybe allow a map of pointers?
00081     SiPixelGainCalibrationServiceBase * theSiPixelGainCalibration_;
00082     std::string clusterMode_;               // user's choice of the clusterizer
00083     PixelClusterizerBase * clusterizer_;    // what we got (for now, one ptr to base class)
00084     bool readyToCluster_;                   // needed clusterizers valid => good to go!
00085     edm::InputTag src_;
00086 
00088     int32_t maxTotalClusters_;
00089   };
00090 }
00091 
00092 
00093 #endif