1 #ifndef SimG4CMS_CaloSD_h 2 #define SimG4CMS_CaloSD_h 24 #include "G4VPhysicalVolume.hh" 26 #include "G4VGFlashSensitiveDetector.hh" 33 class G4HCofThisEvent;
39 public G4VGFlashSensitiveDetector,
41 public Observer<const BeginOfEvent*>,
42 public Observer<const BeginOfTrack*>,
52 bool ignoreTkID =
false);
56 bool ProcessHits(G4GFlashSpot* aSpot, G4TouchableHistory*)
override;
60 void Initialize(G4HCofThisEvent* HCE)
override;
61 void EndOfEvent(G4HCofThisEvent* eventHC)
override;
62 void clear()
override;
68 void reset()
override;
74 G4ThreeVector
setToLocal(
const G4ThreeVector&,
const G4VTouchable*)
const;
75 G4ThreeVector
setToGlobal(
const G4ThreeVector&,
const G4VTouchable*)
const;
82 double getAttenuation(
const G4Step* aStep,
double birk1,
double birk2,
double birk3)
const;
88 void update(const ::EndOfEvent*)
override;
96 virtual uint16_t
getDepth(
const G4Step*);
167 std::map<int, TrackWithHistory*>
tkMap;
171 #endif // SimG4CMS_CaloSD_h
virtual bool getFromLibrary(const G4Step *step)
std::vector< PCaloHit > PCaloHitContainer
void setNumberCheckedHits(int val)
void updateHit(CaloG4Hit *)
virtual uint16_t getDepth(const G4Step *)
virtual double getEnergyDeposit(const G4Step *step)
uint32_t setDetUnitId(const G4Step *step) override=0
virtual int getTrackID(const G4Track *)
void Initialize(G4HCofThisEvent *HCE) override
void processHit(const G4Step *step)
void fillHits(edm::PCaloHitContainer &, const std::string &) override
virtual void initEvent(const BeginOfEvent *)
void cleanHitCollection()
CaloSD(const std::string &aSDname, const edm::EventSetup &es, const SensitiveDetectorCatalog &clg, edm::ParameterSet const &p, const SimTrackManager *, float timeSlice=1., bool ignoreTkID=false)
std::unique_ptr< CaloSlaveSD > slave
void resetForNewPrimary(const G4Step *)
G4bool ProcessHits(G4Step *step, G4TouchableHistory *) override
G4ThreeVector setToGlobal(const G4ThreeVector &, const G4VTouchable *) const
CaloG4Hit * createNewHit(const G4Step *, const G4Track *)
void storeHit(CaloG4Hit *)
virtual bool filterHit(CaloG4Hit *, double)
G4ThreeVector setToLocal(const G4ThreeVector &, const G4VTouchable *) const
bool hitExists(const G4Step *)
std::unique_ptr< CaloMeanResponse > meanResponse
std::map< CaloHitID, CaloG4Hit * > hitMap
void EndOfEvent(G4HCofThisEvent *eventHC) override
double getAttenuation(const G4Step *aStep, double birk1, double birk2, double birk3) const
CaloG4HitCollection * theHC
virtual int setTrackID(const G4Step *)
G4THitsCollection< CaloG4Hit > CaloG4HitCollection
std::map< int, TrackWithHistory * > tkMap
std::vector< std::unique_ptr< CaloG4Hit > > reusehit
const SimTrackManager * m_trackManager
void clearHits() override
double getResponseWt(const G4Track *)
bool saveHit(CaloG4Hit *)
G4ThreeVector entrancePoint
G4ThreeVector entranceLocal
void update(const BeginOfRun *) override
This routine will be called when the appropriate signal arrives.
void setParameterized(bool val)