CMS 3D CMS Logo

TkAccumulatingSensitiveDetector.h
Go to the documentation of this file.
1 #ifndef SimG4CMS_TkAccumulatingSensitiveDetector_H
2 #define SimG4CMS_TkAccumulatingSensitiveDetector_H
3 
14 
15 #include "G4Step.hh"
16 #include "G4StepPoint.hh"
17 #include "G4Track.hh"
18 
19 #include <string>
20 
21 class TrackInformation;
22 class SimTrackManager;
23 class TrackingSlaveSD;
24 class FrameRotation;
25 class UpdatablePSimHit;
29 
31 public SensitiveTkDetector,
32 public Observer<const BeginOfEvent*>,
33 public Observer<const BeginOfTrack*>,
34 public Observer<const BeginOfJob*>
35 {
36 public:
39  edm::ParameterSet const &,
40  const SimTrackManager*);
42  bool ProcessHits(G4Step *,G4TouchableHistory *) override;
43  uint32_t setDetUnitId(G4Step*) override;
44  void EndOfEvent(G4HCofThisEvent*) override;
45 
46  void fillHits(edm::PSimHitContainer&, std::string use) override;
47  std::vector<std::string> getNames() override;
48  std::string type();
49 
50 private:
51  virtual void sendHit();
52  virtual void updateHit(G4Step *);
53  virtual bool newHit(G4Step *);
54  virtual bool closeHit(G4Step *);
55  virtual void createHit(G4Step *);
57  void update(const BeginOfEvent *) override;
58  void update(const BeginOfTrack *) override;
59  void update(const BeginOfJob *) override;
60  void clearHits() override;
61  Local3DPoint toOrcaRef(Local3DPoint ,G4VPhysicalVolume *);
62  int tofBin(float);
72  G4VPhysicalVolume * oldVolume;
74  double theSigma;
75  uint32_t lastId;
76  unsigned int lastTrack;
77  int eventno;
78  // cache stuff for debugging
79  float px,py,pz;
81  bool printHits;
85  float energyCut;
87  //
88  // definition of Tracker volume
89  //
90  float rTracker;
91  float zTracker;
92 
94 };
95 
96 #endif
97 
98 
99 
100 
101 
TrackInformation * getOrCreateTrackInformation(const G4Track *)
void update(const BeginOfEvent *) override
This routine will be called when the appropriate signal arrives.
void fillHits(edm::PSimHitContainer &, std::string use) override
Local3DPoint toOrcaRef(Local3DPoint, G4VPhysicalVolume *)
bool ProcessHits(G4Step *, G4TouchableHistory *) override
type of data representation of DDCompactView
Definition: DDCompactView.h:90
TrackerG4SimHitNumberingScheme * numberingScheme_
std::vector< std::string > getNames() override
std::vector< PSimHit > PSimHitContainer
void EndOfEvent(G4HCofThisEvent *) override
TkAccumulatingSensitiveDetector(std::string, const DDCompactView &, const SensitiveDetectorCatalog &, edm::ParameterSet const &, const SimTrackManager *)
G4ProcessTypeEnumerator * theG4ProcessTypeEnumerator