Go to the documentation of this file.00001 #ifndef Forward_TotemTestGem_h
00002 #define Forward_TotemTestGem_h 1
00003
00004
00005
00006
00007
00016
00017
00018
00019
00020
00021
00022
00023 #include <iostream>
00024 #include <memory>
00025 #include <vector>
00026 #include <string>
00027
00028
00029 #include "SimG4Core/Notification/interface/Observer.h"
00030 #include "SimG4Core/Notification/interface/BeginOfJob.h"
00031 #include "SimG4Core/Notification/interface/BeginOfEvent.h"
00032 #include "SimG4Core/Notification/interface/EndOfEvent.h"
00033 #include "SimG4Core/Watcher/interface/SimProducer.h"
00034 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00035
00036 #include "SimDataFormats/Forward/interface/TotemTestHistoClass.h"
00037 #include "SimG4CMS/Forward/interface/TotemG4Hit.h"
00038
00039 class G4Step;
00040
00041 class TotemTestGem : public SimProducer,
00042 public Observer<const BeginOfEvent *>,
00043 public Observer<const EndOfEvent *> {
00044
00045 public:
00046
00047 TotemTestGem(const edm::ParameterSet &p);
00048 virtual ~TotemTestGem();
00049
00050 virtual void produce(edm::Event&, const edm::EventSetup&);
00051
00052 private:
00053
00054 void update(const BeginOfEvent * evt);
00055 void update(const EndOfEvent * evt);
00056
00057 void clear();
00058 void fillEvent(TotemTestHistoClass&);
00059
00060 private:
00061
00062
00063 std::vector<std::string> names;
00064 int evtnum;
00065 std::vector<TotemG4Hit*> hits;
00066
00067 };
00068
00069 #endif