Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-05 08:17:49

0001 // Tell emacs that this is a C++ source
0002 //  -*- C++ -*-.
0003 #ifndef G4DETECTORS_PHG4HCALSTEPPINGACTION_H
0004 #define G4DETECTORS_PHG4HCALSTEPPINGACTION_H
0005 
0006 #include <g4main/PHG4SteppingAction.h>
0007 
0008 #include <cmath>
0009 
0010 class G4Step;
0011 class PHCompositeNode;
0012 class PHG4HcalDetector;
0013 class PHG4Hit;
0014 class PHG4HitContainer;
0015 class PHG4Shower;
0016 
0017 class PHG4HcalSteppingAction : public PHG4SteppingAction
0018 {
0019  public:
0020   //! constructor
0021   explicit PHG4HcalSteppingAction(PHG4HcalDetector*);
0022 
0023   //! destroctor
0024   ~PHG4HcalSteppingAction() override;
0025 
0026   //! stepping action
0027   bool UserSteppingAction(const G4Step*, bool) override;
0028 
0029   //! reimplemented from base class
0030   void SetInterfacePointers(PHCompositeNode*) override;
0031 
0032   void set_zmin(const float z) { zmin = z; }
0033   void set_zmax(const float z) { zmax = z; }
0034 
0035   void SetLightScintModel(const bool b = true)
0036   {
0037     light_scint_model_ = b;
0038   }
0039 
0040  private:
0041   //! pointer to the detector
0042   PHG4HcalDetector* detector_;
0043 
0044   //! pointer to hit container
0045   PHG4HitContainer* m_HitContainer = nullptr;
0046   PHG4HitContainer* m_AbsorberHits = nullptr;
0047   PHG4HitContainer* m_SaveHitContainer = nullptr;
0048   PHG4Hit* m_Hit = nullptr;
0049   PHG4Shower* m_SaveShower = nullptr;
0050   float zmin = NAN;
0051   float zmax = NAN;
0052 
0053   bool light_scint_model_ = true;
0054 };
0055 
0056 #endif  // PHG4VHcalSteppingAction_h