Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PHG4SpacalPrototype4Detector.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file PHG4SpacalPrototype4Detector.h
1 // Tell emacs that this is a C++ source
2 // -*- C++ -*-.
3 
4 #ifndef G4CALOPROTOTYPE_PHG4SPACALPROTOTYPE4DETECTOR_H
5 #define G4CALOPROTOTYPE_PHG4SPACALPROTOTYPE4DETECTOR_H
6 
8 
9 #include <g4main/PHG4Detector.h>
10 
11 #include <Geant4/G4Transform3D.hh>
12 #include <Geant4/G4Types.hh>
13 
14 #include <map>
15 #include <string> // for string
16 #include <utility>
17 
18 class G4LogicalVolume;
19 class G4UserLimits;
20 class G4VPhysicalVolume;
21 class G4VSolid;
22 class PHCompositeNode;
23 class PHG4Subsystem;
24 class PHParameters;
25 
27 {
28  public:
30 
32 
33  virtual ~PHG4SpacalPrototype4Detector(void);
34 
35  virtual void
36  ConstructMe(G4LogicalVolume* world);
37 
38  virtual std::pair<G4LogicalVolume*, G4Transform3D>
40 
42  virtual G4LogicalVolume*
45  virtual G4LogicalVolume*
46  Construct_LightGuide(const SpacalGeom_t::geom_tower& tower, const int index_x, const int index_y);
47 
49  virtual int
51  const SpacalGeom_t::geom_tower& tower, G4LogicalVolume* LV_tower);
52 
53  virtual G4LogicalVolume*
54  Construct_Fiber(const G4double length, const std::string& id);
55 
56  void
57  SetActive(const int i = 1)
58  {
59  active = i;
60  }
61 
62  void
63  SetAbsorberActive(const int i = 1)
64  {
65  absorberactive = i;
66  }
67 
68  void
70  {
71  detector_type = typ;
72  }
73 
75 
76  void
78  {
80  }
81 
82  const std::string
83  SuperDetector() const
84  {
85  return superdetector;
86  }
87 
88  virtual void
89  Print(const std::string& what = "ALL") const;
90 
91  const SpacalGeom_t*
92  get_geom() const
93  {
94  return _geom;
95  }
96 
97  enum
98  {
101  ABSORBER = -1,
102  SUPPORT = -2,
103  INACTIVE = -100
104  };
105 
106  protected:
108 
109  G4VSolid* cylinder_solid;
110  G4LogicalVolume* cylinder_logic;
112  std::map<const G4VPhysicalVolume*, int> fiber_core_vol;
113 
115  std::map<const G4VPhysicalVolume*, int> fiber_vol;
116 
118  std::map<const G4VPhysicalVolume*, int> calo_vol;
119 
121  std::map<const G4VPhysicalVolume*, int> block_vol;
122 
123  int active;
127 
128  G4UserLimits* step_limits;
129  G4UserLimits* clading_step_limits;
130  G4UserLimits* fiber_core_step_limits;
131 
132  private:
134 };
135 
136 #endif