00001 #ifndef EcalDigiToRaw_H 00002 #define EcalDigiToRaw_H 00003 00004 // 00005 // Package: EcalDigiToRaw 00006 // Class: EcalDigiToRaw 00007 // 00015 // 00016 // Original Author: Emmanuelle Perez 00017 // Created: Sat Nov 25 13:59:51 CET 2006 00018 // $Id: EcalDigiToRaw.h,v 1.9 2010/01/13 21:55:15 wmtan Exp $ 00019 // 00020 // 00021 00022 00023 // system include files 00024 #include <memory> 00025 #include <iostream> 00026 #include <string> 00027 00028 00029 // user include files 00030 #include "FWCore/Framework/interface/Frameworkfwd.h" 00031 #include "FWCore/Framework/interface/EDProducer.h" 00032 00033 #include "FWCore/Framework/interface/Event.h" 00034 #include "FWCore/Framework/interface/MakerMacros.h" 00035 00036 #include "FWCore/ParameterSet/interface/ParameterSet.h" 00037 00038 #include "EventFilter/EcalDigiToRaw/interface/TowerBlockFormatter.h" 00039 #include "EventFilter/EcalDigiToRaw/interface/TCCBlockFormatter.h" 00040 #include "EventFilter/EcalDigiToRaw/interface/BlockFormatter.h" 00041 #include "EventFilter/EcalDigiToRaw/interface/SRBlockFormatter.h" 00042 00043 00044 00045 // 00046 // class decleration 00047 // 00048 00049 class EcalDigiToRaw : public edm::EDProducer { 00050 public: 00051 EcalDigiToRaw(const edm::ParameterSet& pset); 00052 virtual ~EcalDigiToRaw(); 00053 00054 void beginJob(); 00055 void produce(edm::Event& e, const edm::EventSetup& c); 00056 void endJob() ; 00057 00058 typedef long long Word64; 00059 typedef unsigned int Word32; 00060 00061 int* GetCounter() {return &counter_ ;} 00062 bool GetDebug() {return debug_ ;} 00063 int* GetOrbit() {return &orbit_number_ ;} 00064 int* GetBX() {return &bx_ ;} 00065 int* GetLV1() {return &lv1_ ;} 00066 int* GetRunNumber() {return &runnumber_ ;} 00067 bool GetDoBarrel() {return doBarrel_ ;} 00068 bool GetDoEndCap() {return doEndCap_ ;} 00069 bool GetDoSR() {return doSR_ ;} 00070 bool GetDoTower() {return doTower_ ;} 00071 bool GetDoTCC() {return doTCC_ ;} 00072 00073 std::vector<int32_t>* GetListDCCId() {return &listDCCId_ ;} 00074 00075 static const int BXMAX = 2808; 00076 00077 00078 private: 00079 00080 00081 // ----------member data --------------------------- 00082 00083 int counter_; 00084 int orbit_number_; 00085 bool debug_; 00086 int runnumber_; 00087 int bx_; 00088 int lv1_; 00089 00090 bool doTCC_; 00091 bool doSR_; 00092 bool doTower_; 00093 00094 edm::InputTag labelTT_ ; 00095 edm::InputTag labelEBSR_ ; 00096 edm::InputTag labelEESR_ ; 00097 00098 bool doBarrel_; 00099 bool doEndCap_; 00100 00101 std::vector<int32_t> listDCCId_; 00102 00103 std::string label_; 00104 std::string instanceNameEB_; 00105 std::string instanceNameEE_; 00106 00107 TowerBlockFormatter* Towerblockformatter_; 00108 TCCBlockFormatter* TCCblockformatter_; 00109 BlockFormatter* Headerblockformatter_; 00110 SRBlockFormatter* SRblockformatter_; 00111 00112 00113 }; 00114 00115 //define this as a plug-in 00116 // DEFINE_FWK_MODULE(EcalDigiToRaw); 00117 00118 #endif 00119