Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-06 08:19:03

0001 // Tell emacs that this is a C++ source
0002 //  -*- C++ -*-.
0003 #ifndef G4DETECTORS_PHG4SPHENIXMAGNETSUBSYSTEM_H
0004 #define G4DETECTORS_PHG4SPHENIXMAGNETSUBSYSTEM_H
0005 
0006 #include "PHG4DetectorSubsystem.h"
0007 
0008 #include <string>
0009 
0010 class PHCompositeNode;
0011 class PHG4Detector;
0012 class PHG4DisplayAction;
0013 class PHG4sPHENIXMagnetDetector;
0014 class PHG4SteppingAction;
0015 
0016 class PHG4sPHENIXMagnetSubsystem : public PHG4DetectorSubsystem
0017 {
0018  public:
0019   //! constructor
0020   PHG4sPHENIXMagnetSubsystem(const std::string& name = "HCALOUT", const int layer = 0);
0021 
0022   //! destructor
0023   ~PHG4sPHENIXMagnetSubsystem() override;
0024 
0025   /*!
0026   creates the Detector object. Creates the stepping action
0027   creates relevant hit nodes that will be populated by the stepping action and stored in the output DST
0028   */
0029   int InitRunSubsystem(PHCompositeNode*) override;
0030 
0031   //! event processing
0032   /*!
0033   get all relevant nodes from top nodes (namely hit list)
0034   and pass that to the stepping action
0035   */
0036   int process_event(PHCompositeNode*) override;
0037 
0038   //! Print info (from SubsysReco)
0039   void Print(const std::string& what = "ALL") const override;
0040 
0041   //! accessors (reimplemented)
0042   PHG4Detector* GetDetector(void) const override;
0043   PHG4SteppingAction* GetSteppingAction() const override { return m_SteppingAction; }
0044   PHG4DisplayAction* GetDisplayAction() const override { return m_DisplayAction; }
0045 
0046   void SetLightCorrection(const double inner_radius, const double inner_corr, const double outer_radius, const double outer_corr);
0047 
0048  private:
0049   void SetDefaultParameters() override;
0050 
0051   //! detector geometry
0052   /*! defives from PHG4Detector */
0053   PHG4sPHENIXMagnetDetector* m_Detector = nullptr;
0054 
0055   //! particle tracking "stepping" action
0056   /*! derives from PHG4SteppingActions */
0057   PHG4SteppingAction* m_SteppingAction = nullptr;
0058 
0059   //! display attribute setting
0060   /*! derives from PHG4DisplayAction */
0061   PHG4DisplayAction* m_DisplayAction = nullptr;
0062 };
0063 
0064 #endif