clas12root
Loading...
Searching...
No Matches
cherenkov.h
Go to the documentation of this file.
1/*
2 * To change this license header, choose License Headers in Project Properties.
3 * To change this template file, choose Tools | Templates
4 * and open the template in the editor.
5 */
6
7/*
8 * File: cherenkov.h
9 * Author: dglazier
10 *
11 * Created on April 27, 2017, 10:01 AM
12 */
13
14#ifndef CLAS12_CHERENKOV_H
15#define CLAS12_CHERENKOV_H
16
17#include "particle_detector.h"
18
19
20namespace clas12 {
21
23
24
25 public:
26
27
28 cherenkov()=default;
29
30 cherenkov(hipo::schema __schema);
31
32 ~cherenkov() override=default;
33
34 //getter funtions for items in cherenkov bank
35 double getTime() const noexcept{
36 if(_index>-1)return getFloat(_time_order,_index);
37 return 0;
38 }
39 double getNphe() const noexcept{
40 if(_index>-1)return getFloat(_nphe_order,_index);
41 return 0;
42 }
43 double getPath() const noexcept{
44 if(_index>-1)return getFloat(_path_order,_index);
45 return 0;
46 }
47 int getSector() const noexcept{
48 if(_index>-1)return getByte(_sector_order,_index);
49 return 0;
50 }
51 double getChi2() const noexcept{
52 if(_index>-1)return getFloat(_chi2_order,_index);
53 return 0;
54 }
55 double getX() const noexcept{
56 if(_index>-1)return getFloat(_x_order,_index);
57 return 0;
58 }
59 double getY() const noexcept{
60 if(_index>-1)return getFloat(_y_order,_index);
61 return 0;
62 }
63 double getZ() const noexcept{
64 if(_index>-1)return getFloat(_z_order,_index);
65 return 0;
66 }
67 double getDtheta() const noexcept{
68 if(_index>-1)return getFloat(_dtheta_order,_index);
69 return 0;
70 }
71 double getDPhi() const noexcept{
72 if(_index>-1)return getFloat(_dphi_order,_index);
73 return 0;
74 }
75 int getStatus() const noexcept{
76 if(_index>-1)return getShort(_status_order,_index);
77 return 0;
78 }
79
80
81 private:
82
83 int _nphe_order=-1;
84 int _path_order=-1;
85 int _time_order=-1;
86 int _dphi_order=-1;
87 int _dtheta_order=-1;
88 int _sector_order=-1;
89 int _x_order=-1;
90 int _y_order=-1;
91 int _z_order=-1;
92 int _chi2_order=-1;
93 int _status_order=-1;
94
95
96
97 }; //class cherenkov
98
100 using cher_uptr=std::unique_ptr<clas12::cherenkov>;
101
102}//namespace clas12
103
104#endif /* UTILS_H */
Definition cherenkov.h:22
double getDtheta() const noexcept
Definition cherenkov.h:67
int getStatus() const noexcept
Definition cherenkov.h:75
~cherenkov() override=default
double getX() const noexcept
Definition cherenkov.h:55
double getY() const noexcept
Definition cherenkov.h:59
double getNphe() const noexcept
Definition cherenkov.h:39
double getDPhi() const noexcept
Definition cherenkov.h:71
cherenkov()=default
double getPath() const noexcept
Definition cherenkov.h:43
double getZ() const noexcept
Definition cherenkov.h:63
double getTime() const noexcept
Definition cherenkov.h:35
double getChi2() const noexcept
Definition cherenkov.h:51
int getSector() const noexcept
Definition cherenkov.h:47
int _index
Definition particle_detector.h:83
Definition calextras.cpp:10
clas12::cherenkov * cher_ptr
Definition cherenkov.h:99
std::unique_ptr< clas12::cherenkov > cher_uptr
Definition cherenkov.h:100