CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
FastTimerSD.h
Go to the documentation of this file.
1 #ifndef SimG4CMSForward_FastTimerSD_h
2 #define SimG4CMSForward_FastTimerSD_h
3 
6 
10 
14 
15 #include "G4Step.hh"
16 #include "G4StepPoint.hh"
17 #include "G4Track.hh"
18 #include "G4VPhysicalVolume.hh"
19 
20 #include <string>
21 
22 class TrackingSlaveSD;
23 
24 class TrackInformation;
25 class SimTrackManager;
26 class TrackingSlaveSD;
27 class UpdatablePSimHit;
30 
31 
32 //-------------------------------------------------------------------
33 
35  public Observer<const BeginOfRun *>,
36  public Observer<const BeginOfEvent*>,
37  public Observer<const EndOfEvent*> {
38 
39 public:
40 
42  edm::ParameterSet const &, const SimTrackManager* );
43 
44 
45  virtual ~FastTimerSD();
46 
47  virtual bool ProcessHits(G4Step *,G4TouchableHistory *);
48  virtual uint32_t setDetUnitId(G4Step*);
49 
50  virtual void Initialize(G4HCofThisEvent * HCE);
51  virtual void EndOfEvent(G4HCofThisEvent * eventHC);
52  virtual void clear();
53  virtual void DrawAll();
54  virtual void PrintAll();
55 
56  virtual double getEnergyDeposit(G4Step* step);
58 
59  std::vector<std::string> getNames();
60 
61 private:
62  void update(const BeginOfRun *);
63  void update(const BeginOfEvent *);
64  void update(const ::EndOfEvent *);
65  virtual void clearHits();
66 
67 private:
68 
69  G4ThreeVector SetToLocal(const G4ThreeVector& global);
70  G4ThreeVector SetToLocalExit(const G4ThreeVector& globalPoint);
71  void GetStepInfo(G4Step* aStep);
72  G4bool HitExists();
73  void CreateNewHit();
74  void UpdateHit();
75  void StoreHit(BscG4Hit*);
76  void ResetForNewPrimary();
77  void Summarize();
78 
79 
80 private:
81 
84  int type;
85 
86  G4ThreeVector entrancePoint, exitPoint;
87  G4ThreeVector theEntryPoint, theExitPoint;
88 
90  G4int primID ;
91 
93  G4int hcID;
96 
97  G4int tsID;
99  G4Track* theTrack;
100  G4VPhysicalVolume* currentPV;
103  G4double tSlice;
104 
105  G4StepPoint* preStepPoint;
106  G4StepPoint* postStepPoint;
107  float edeposit;
108 
109  G4ThreeVector hitPoint;
110  G4ThreeVector hitPointExit;
111  G4ThreeVector hitPointLocal;
112  G4ThreeVector hitPointLocalExit;
113 
114  float Pabs, Tof, Eloss;
115  short ParticleType;
117 
118  int ParentId;
119  float Vx,Vy,Vz;
120  float X,Y,Z;
121 
122  int eventno;
123 
124 protected:
125 
127  G4int emPDG;
128  G4int epPDG;
129  G4int gammaPDG;
130 };
131 
132 #endif
133 
134 
135 
136 
std::string name
Definition: FastTimerSD.h:92
G4ThreeVector hitPoint
Definition: FastTimerSD.h:109
G4ThreeVector hitPointExit
Definition: FastTimerSD.h:110
virtual void clear()
Definition: FastTimerSD.cc:382
G4ThreeVector SetToLocalExit(const G4ThreeVector &globalPoint)
Definition: FastTimerSD.cc:344
void update(const BeginOfRun *)
This routine will be called when the appropriate signal arrives.
Definition: FastTimerSD.cc:406
float edepositHAD
Definition: FastTimerSD.h:126
G4ThreeVector theEntryPoint
Definition: FastTimerSD.h:87
G4int tSliceID
Definition: FastTimerSD.h:102
virtual void Initialize(G4HCofThisEvent *HCE)
Definition: FastTimerSD.cc:91
virtual double getEnergyDeposit(G4Step *step)
Definition: FastTimerSD.cc:87
void UpdateHit()
Definition: FastTimerSD.cc:316
BscG4Hit * currentHit
Definition: FastTimerSD.h:98
uint32_t unitID
Definition: FastTimerSD.h:101
float edeposit
Definition: FastTimerSD.h:107
short ParticleType
Definition: FastTimerSD.h:115
type of data representation of DDCompactView
Definition: DDCompactView.h:77
G4int tsID
Definition: FastTimerSD.h:97
G4ThreeVector SetToLocal(const G4ThreeVector &global)
Definition: FastTimerSD.cc:336
virtual void PrintAll()
Definition: FastTimerSD.cc:386
G4bool HitExists()
Definition: FastTimerSD.cc:198
TrackingSlaveSD * slave
Definition: FastTimerSD.h:82
G4int gammaPDG
Definition: FastTimerSD.h:129
G4int primID
Definition: FastTimerSD.h:90
virtual ~FastTimerSD()
Definition: FastTimerSD.cc:81
FastTimerSD(std::string, const DDCompactView &, const SensitiveDetectorCatalog &, edm::ParameterSet const &, const SimTrackManager *)
Definition: FastTimerSD.cc:31
G4StepPoint * postStepPoint
Definition: FastTimerSD.h:106
const SimTrackManager * theManager
Definition: FastTimerSD.h:95
G4ThreeVector hitPointLocalExit
Definition: FastTimerSD.h:112
G4VPhysicalVolume * currentPV
Definition: FastTimerSD.h:100
void ResetForNewPrimary()
Definition: FastTimerSD.cc:238
void StoreHit(BscG4Hit *)
Definition: FastTimerSD.cc:246
FastTimeDDDConstants * ftcons
Definition: FastTimerSD.h:83
virtual void DrawAll()
Definition: FastTimerSD.cc:384
G4ThreeVector hitPointLocal
Definition: FastTimerSD.h:111
G4Track * theTrack
Definition: FastTimerSD.h:99
float incidentEnergy
Definition: FastTimerSD.h:89
BscG4HitCollection * theHC
Definition: FastTimerSD.h:94
virtual bool ProcessHits(G4Step *, G4TouchableHistory *)
Definition: FastTimerSD.cc:106
std::vector< std::string > getNames()
Definition: FastTimerSD.cc:422
G4StepPoint * preStepPoint
Definition: FastTimerSD.h:105
void fillHits(edm::PSimHitContainer &, std::string use)
Definition: FastTimerSD.cc:393
G4ThreeVector entrancePoint
Definition: FastTimerSD.h:86
G4ThreeVector theExitPoint
Definition: FastTimerSD.h:87
uint32_t previousUnitID
Definition: FastTimerSD.h:101
float PhiAtEntry
Definition: FastTimerSD.h:116
float edepositEM
Definition: FastTimerSD.h:126
G4double tSlice
Definition: FastTimerSD.h:103
virtual uint32_t setDetUnitId(G4Step *)
Definition: FastTimerSD.cc:175
std::vector< PSimHit > PSimHitContainer
G4THitsCollection< BscG4Hit > BscG4HitCollection
float ThetaAtEntry
Definition: FastTimerSD.h:116
void Summarize()
Definition: FastTimerSD.cc:380
virtual void EndOfEvent(G4HCofThisEvent *eventHC)
Definition: FastTimerSD.cc:352
G4int hcID
Definition: FastTimerSD.h:93
G4ThreeVector exitPoint
Definition: FastTimerSD.h:86
virtual void clearHits()
Definition: FastTimerSD.cc:418
void CreateNewHit()
Definition: FastTimerSD.cc:257
G4int primaryID
Definition: FastTimerSD.h:102
void GetStepInfo(G4Step *aStep)
Definition: FastTimerSD.cc:124