Jpp  18.5.2
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JPMTW0.hh
Go to the documentation of this file.
1 #ifndef __JFIT__JPMTW0__
2 #define __JFIT__JPMTW0__
3 
4 #include "JGeometry3D/JAxis3D.hh"
5 
6 
7 /**
8  * \author mdejong
9  */
10 
11 namespace JFIT {}
12 namespace JPP { using namespace JFIT; }
13 
14 namespace JFIT {
15 
17 
18 
19  /**
20  * Auxiliary class for handling PMT geometry, rate and response.
21  */
22  struct JPMTW0 :
23  public JAxis3D
24  {
25  /**
26  * Default constructor.
27  */
28  JPMTW0() :
29  JAxis3D(),
30  __R(0.0),
31  __n(0)
32  {}
33 
34 
35  /**
36  * Constructor.
37  *
38  * \param pmt PMT axis
39  * \param rate_Hz rate [Hz]
40  * \param numberOfHits number of hits
41  */
42  JPMTW0(const JAxis3D& pmt,
43  const double rate_Hz,
44  const int numberOfHits) :
45  JAxis3D(pmt),
46  __R(rate_Hz),
47  __n(numberOfHits)
48  {}
49 
50 
51  /**
52  * Get rate.
53  *
54  * \return rate [Hz]
55  */
56  inline double getR() const
57  {
58  return __R;
59  }
60 
61 
62  /**
63  * Get number of hits.
64  *
65  * \return number of hits
66  */
67  inline int getN() const
68  {
69  return __n;
70  }
71 
72  protected:
73  double __R; //!< rate [Hz]
74  int __n; //!< number of hits
75  };
76 }
77 
78 #endif
double getR() const
Get rate.
Definition: JPMTW0.hh:56
Auxiliary class for handling PMT geometry, rate and response.
Definition: JPMTW0.hh:22
JPMTW0()
Default constructor.
Definition: JPMTW0.hh:28
Axis object.
Definition: JAxis3D.hh:38
double __R
rate [Hz]
Definition: JPMTW0.hh:73
int __n
number of hits
Definition: JPMTW0.hh:74
int getN() const
Get number of hits.
Definition: JPMTW0.hh:67
JPMTW0(const JAxis3D &pmt, const double rate_Hz, const int numberOfHits)
Constructor.
Definition: JPMTW0.hh:42