Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-05 08:18:03

0001 #ifndef G4HISTOS_G4ROOTHITCONTAINER_H
0002 #define G4HISTOS_G4ROOTHITCONTAINER_H
0003 
0004 #include <phool/PHObject.h>
0005 
0006 #include <iostream>  // for cout, ostream
0007 #include <limits>
0008 
0009 class PHG4Hit;
0010 class TClonesArray;
0011 
0012 class G4RootHitContainer : public PHObject
0013 {
0014  public:
0015   G4RootHitContainer();
0016   ~G4RootHitContainer() override;
0017 
0018   // from PHObject
0019   void identify(std::ostream& os = std::cout) const override;
0020   void Reset() override;
0021 
0022   PHG4Hit* AddHit(const PHG4Hit* g4hit);
0023   void set_etotal(const float e) { etotal = e; }
0024   float get_etotal() const { return etotal; }
0025 
0026   void set_eion(const float e) { eion = e; }
0027   float get_eion() const { return eion; }
0028 
0029   void set_leakage(const float f) { leakage = f; }
0030   float get_leakage() const { return leakage; }
0031 
0032   void set_event(const int i) { event = i; }
0033   int get_event() const { return event; }
0034 
0035  protected:
0036   float etotal{std::numeric_limits<float>::quiet_NaN()};
0037   float eion{std::numeric_limits<float>::quiet_NaN()};
0038   float leakage{std::numeric_limits<float>::quiet_NaN()};
0039   int event{0};
0040   TClonesArray* SnglHits{nullptr};
0041 
0042   ClassDefOverride(G4RootHitContainer, 1)
0043 };
0044 
0045 #endif