GeoModel - GeoModelCore
GeoCons.h
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef GEOMODELKERNEL_GEOCONS_H
6 #define GEOMODELKERNEL_GEOCONS_H
7 
8 #include "GeoModelKernel/GeoShape.h"
9 
10 class GeoCons : public GeoShape
11 {
12  public:
13  GeoCons (double RMin1, double RMin2, double RMax1, double RMax2, double DZ, double SPhi, double DPhi);
14 
15  // Returns the volume of the shape, for mass inventory
16  virtual double volume () const;
17 
18  // Returns the CONS shape type, as a string.
19  virtual const std::string & type () const;
20 
21  // Returns the CONS shape type, as a coded integer.
22  virtual ShapeType typeID () const;
23 
24  // Executes a GeoShapeAction
25  virtual void exec (GeoShapeAction *action) const;
26 
27  // For type identification.
28  static const std::string& getClassType ();
29 
30  // For type identification.
31  static ShapeType getClassTypeID ();
32 
33  // Inside radius at -dZ
34  const double& getRMin1 () const;
35 
36  // Inside radius at +dZ
37  const double& getRMin2 () const;
38 
39  // Outside radius at -dZ
40  const double& getRMax1 () const;
41 
42  // Outside radius at +dZ
43  const double& getRMax2 () const;
44 
45  // Half length in Z direction.
46  const double& getDZ () const;
47 
48  // Starting angle of the segment in radians
49  const double& getSPhi () const;
50 
51  // Delta angle of the segment in radians.
52  const double& getDPhi () const;
53 
54  protected:
55  virtual ~GeoCons();
56 
57  private:
58  GeoCons(const GeoCons &right);
59  GeoCons & operator=(const GeoCons &right);
60 
61  static const std::string s_classType;
62  static const ShapeType s_classTypeID;
63 
64  double m_rMin1;
65  double m_rMin2;
66  double m_rMax1;
67  double m_rMax2;
68  double m_dZ;
69  double m_sPhi;
70  double m_dPhi;
71 };
72 
73 inline const std::string& GeoCons::getClassType ()
74 {
75  return s_classType;
76 }
77 
78 inline ShapeType GeoCons::getClassTypeID ()
79 {
80  return s_classTypeID;
81 }
82 
83 inline const double& GeoCons::getRMin1 () const
84 {
85  return m_rMin1;
86 }
87 
88 inline const double& GeoCons::getRMin2 () const
89 {
90  return m_rMin2;
91 }
92 
93 inline const double& GeoCons::getRMax1 () const
94 {
95  return m_rMax1;
96 }
97 
98 inline const double& GeoCons::getRMax2 () const
99 {
100  return m_rMax2;
101 }
102 
103 inline const double& GeoCons::getDZ () const
104 {
105  return m_dZ;
106 }
107 
108 inline const double& GeoCons::getSPhi () const
109 {
110  return m_sPhi;
111 }
112 
113 inline const double& GeoCons::getDPhi () const
114 {
115  return m_dPhi;
116 }
117 
118 #endif
This class is a visitor for shapes. It allows a navigation of the boolean expression tree for shapes...
This class describes a Shape. Shapes will be able to do the following things:
Definition: GeoShape.h:38