CMS 3D CMS Logo

/data/doxygen/doxygen-1.7.3/gen/CMSSW_4_2_8/src/SimCalorimetry/EcalTestBeam/interface/EcalTBDigiProducer.h

Go to the documentation of this file.
00001 #ifndef ECALTBDIGIPRODUCER_H
00002 #define ECALTBDIGIPRODUCER_H
00003 
00004 #include "FWCore/Framework/interface/EDProducer.h"
00005 #include "FWCore/Framework/interface/Event.h"
00006 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00007 #include "FWCore/Framework/interface/EventSetup.h"
00008 #include "SimCalorimetry/CaloSimAlgos/interface/CaloHitRespoNew.h"
00009 #include "SimCalorimetry/CaloSimAlgos/interface/CaloTDigitizer.h"
00010 #include "SimCalorimetry/EcalSimAlgos/interface/EcalTDigitizer.h"
00011 #include "SimGeneral/NoiseGenerators/interface/CorrelatedNoisifier.h"
00012 #include "SimCalorimetry/EcalSimAlgos/interface/EcalSimParameterMap.h"
00013 #include "SimCalorimetry/EcalSimAlgos/interface/EBShape.h"
00014 #include "SimCalorimetry/EcalSimAlgos/interface/EEShape.h"
00015 #include "SimCalorimetry/EcalSimAlgos/interface/EcalCorrelatedNoiseMatrix.h"
00016 //TB#include "SimCalorimetry/EcalSimAlgos/interface/ESShape.h"
00017 #include "DataFormats/EcalDigi/interface/EcalDigiCollections.h"
00018 #include "SimCalorimetry/EcalSimAlgos/interface/EcalCoder.h"
00019 #include "SimCalorimetry/EcalSimAlgos/interface/EcalElectronicsSim.h"
00020 //TB#include "SimCalorimetry/EcalSimAlgos/interface/ESElectronicsSimFast.h"
00021 //TB#include "SimCalorimetry/EcalSimAlgos/interface/ESElectronicsSim.h"
00022 #include "SimCalorimetry/EcalSimAlgos/interface/EcalDigitizerTraits.h"
00023 //TB#include "SimCalorimetry/EcalSimAlgos/interface/ESFastTDigitizer.h"
00024 //TB#include "Geometry/CaloGeometry/interface/CaloGeometry.h"
00025 
00026 #include "DataFormats/Math/interface/Error.h"
00027 #include "CalibFormats/CaloObjects/interface/CaloSamples.h"
00028 
00029 //For TB ----------------------------
00030 #include "Geometry/CaloTopology/interface/EcalTrigTowerConstituentsMap.h"
00031 #include "SimCalorimetry/EcalTestBeamAlgos/interface/EcalTBReadout.h"
00032 #include "TBDataFormats/EcalTBObjects/interface/EcalTBTDCSample.h"
00033 #include "TBDataFormats/EcalTBObjects/interface/EcalTBTDCRawInfo.h"
00034 #include "RecoTBCalo/EcalTBTDCReconstructor/interface/EcalTBTDCRecInfoAlgo.h"
00035 //For TB ----------------------------
00036 
00037 class EcalTBDigiProducer : public edm::EDProducer
00038 {
00039 public:
00040 
00041   // The following is not yet used, but will be the primary
00042   // constructor when the parameter set system is available.
00043   //
00044   explicit EcalTBDigiProducer(const edm::ParameterSet& params);
00045   virtual ~EcalTBDigiProducer();
00046 
00048   virtual void produce(edm::Event& event, const edm::EventSetup& eventSetup);
00049 
00050 private:
00051 
00052 //TB  void checkGeometry(const edm::EventSetup & eventSetup);
00053 
00054 //TB  void updateGeometry();
00055 
00056   void checkCalibrations(const edm::EventSetup & eventSetup);
00057 
00058   void setPhaseShift(const DetId & detId);
00059 
00060   void fillTBTDCRawInfo(EcalTBTDCRawInfo & theTBTDCRawInfo);
00061 
00063   typedef EcalTDigitizer<EBDigitizerTraits> EBDigitizer;
00064   typedef EcalTDigitizer<EEDigitizerTraits> EEDigitizer;
00065 //TB  typedef CaloTDigitizer<ESDigitizerTraits> ESDigitizer;
00066 
00067   EBDigitizer * theBarrelDigitizer;
00068   EEDigitizer * theEndcapDigitizer;
00069 //TB  ESDigitizer * theESDigitizer;
00070 //TB  ESFastTDigitizer * theESDigitizerFast;
00071 
00072   const EcalSimParameterMap * theParameterMap;
00073   const EBShape theEBShape;
00074   const EEShape theEEShape;
00075 //TB  const ESShape * theESShape;
00076 
00077   CaloHitRespoNew * theEBResponse;
00078   CaloHitRespoNew * theEEResponse;
00079 //TB  CaloHitResponse * theESResponse;
00080 
00081   CorrelatedNoisifier<EcalCorrMatrix> * theCorrNoise;
00082   EcalCorrMatrix * theNoiseMatrix;
00083 
00084   EcalElectronicsSim * theElectronicsSim;
00085 //TB  ESElectronicsSim * theESElectronicsSim;
00086 //TB  ESElectronicsSimFast * theESElectronicsSimFast;
00087   EcalCoder * theCoder;
00088 
00089   std::string EBdigiCollection_;
00090   std::string EEdigiCollection_;
00091 //TB  std::string ESdigiCollection_;
00092 
00093 //TB  std::string hitsProducer_;
00094 
00095   double EBs25notCont;
00096   double EEs25notCont;
00097 
00098 //For TB -------------------------------------------
00099 
00100       std::string m_barrelHitsName ;
00101       std::string m_endcapHitsName ;
00102 
00103   const EcalTrigTowerConstituentsMap * theTTmap;
00104 
00105   EcalTBReadout * theTBReadout;
00106 
00107   std::string ecalTBInfoLabel;
00108 
00109   bool doPhaseShift;
00110   double thisPhaseShift;
00111 
00112   bool doReadout;
00113 
00114   std::vector<EcalTBTDCRecInfoAlgo::EcalTBTDCRanges> tdcRanges;
00115   bool use2004OffsetConvention_;
00116 
00117   double tunePhaseShift;
00118 //For TB ---------------------
00119 
00120 //TB  bool cosmicsPhase;
00121 //TB  double cosmicsShift;
00122 
00123 //TB  bool doFast; 
00124 };
00125 
00126 #endif