clas12root
Loading...
Searching...
No Matches
forwardtagger.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: forwardtagger.h
9 * Author: dglazier
10 *
11 * Created on April 27, 2017, 10:01 AM
12 */
13
14#ifndef CLAS12_FORWARDTAGGER_H
15#define CLAS12_FORWARDTAGGER_H
16
17#include "particle_detector.h"
18
19
20namespace clas12 {
21
22
24
25
26 public:
27
28
29 forwardtagger()=default;
30
31 forwardtagger(hipo::schema __schema);
32
33 virtual ~forwardtagger()=default;
34
35 //getter funtions for items in forwardtagger bank
36 int getLayer(int index) const noexcept override{
37 if(index>-1)return getByte(_layer_order,index);
38 return 0;
39 }
40 int getLayer() const noexcept override{
41 if(_index>-1)return getByte(_layer_order,_index);
42 return 0;
43 }
44 double getTime() const noexcept{
45 if(_index>-1)return getFloat(_time_order,_index);
46 return 0;
47 }
48 double getEnergy() const noexcept{
49 if(_index>-1)return getFloat(_energy_order,_index);
50 return 0;
51 }
52 double getPath() const noexcept{
53 if(_index>-1)return getFloat(_path_order,_index);
54 return 0;
55 }
56 int getStatus() const noexcept{
57 if(_index>-1)return getShort(_status_order,_index);
58 return 0;
59 }
60 double getX() const noexcept{
61 if(_index>-1)return getFloat(_x_order,_index);
62 return 0;
63 }
64 double getY() const noexcept{
65 if(_index>-1)return getFloat(_y_order,_index);
66 return 0;
67 }
68 double getZ() const noexcept{
69 if(_index>-1)return getFloat(_z_order,_index);
70 return 0;
71 }
72 double getDx() const noexcept{
73 if(_index>-1)return getFloat(_dx_order,_index);
74 return 0;
75 }
76 double getDy() const noexcept{
77 if(_index>-1)return getFloat(_dy_order,_index);
78 return 0;
79 }
80 double getRadius() const noexcept{
81 if(_index>-1)return getFloat(_radius_order,_index);
82 return 0;
83 }
84 int getSizeFT() const noexcept{ //watch-out banks::getSize() !
85 if(_index>-1)return getShort(_size_order,_index);
86 return 0;
87 }
88 double getChi2() const noexcept{
89 if(_index>-1)return getFloat(_chi2_order,_index);
90 return 0;
91 }
92
93
94 private:
95
96 int _energy_order=-1;
97 int _layer_order=-1;
98 int _path_order=-1;
99 int _time_order=-1;
100 int _status_order=-1;
101 int _x_order=-1;
102 int _y_order=-1;
103 int _z_order=-1;
104 int _dx_order=-1;
105 int _dy_order=-1;
106 int _radius_order=-1;
107 int _size_order=-1;
108 int _chi2_order=-1;
109
110
111
112 }; //class forwardtagger
113
114
116 using ft_uptr=std::unique_ptr<clas12::forwardtagger>;
117
118}//namespace clas12
119
120#endif /* UTILS_H */
Definition forwardtagger.h:23
double getPath() const noexcept
Definition forwardtagger.h:52
int getSizeFT() const noexcept
Definition forwardtagger.h:84
double getX() const noexcept
Definition forwardtagger.h:60
double getChi2() const noexcept
Definition forwardtagger.h:88
int getLayer() const noexcept override
Definition forwardtagger.h:40
double getDy() const noexcept
Definition forwardtagger.h:76
double getY() const noexcept
Definition forwardtagger.h:64
int getLayer(int index) const noexcept override
Definition forwardtagger.h:36
virtual ~forwardtagger()=default
double getEnergy() const noexcept
Definition forwardtagger.h:48
double getRadius() const noexcept
Definition forwardtagger.h:80
double getZ() const noexcept
Definition forwardtagger.h:68
double getDx() const noexcept
Definition forwardtagger.h:72
double getTime() const noexcept
Definition forwardtagger.h:44
int getStatus() const noexcept
Definition forwardtagger.h:56
int _index
Definition particle_detector.h:83
Definition calextras.cpp:10
std::unique_ptr< clas12::forwardtagger > ft_uptr
Definition forwardtagger.h:116
clas12::forwardtagger * ft_ptr
Definition forwardtagger.h:115