Neutral Particle Spectrometer analysis code
Loading...
Searching...
No Matches
THcNPSShowerHit.h
Go to the documentation of this file.
1#ifndef ROOT_THcNPSShowerHit
2#define ROOT_THcNPSShowerHit
3
4// HMS calorimeter hits, version 2
5
6#include <set>
7#include <iterator>
8#include <iostream>
9#include <memory>
10#include <vector>
11#include "TMath.h"
12
13using namespace std;
14
15class THcNPSShowerHit { //HMS calorimeter hit class
16
17 Int_t fID, fCol, fRow; //hit block ID, column and row
18 Double_t fX,fY, fZ; //hit X (vert.) , Y (hort) and Z (along spect.axis) coordinates
19 Double_t fE; //hit pulse energy
20 Double_t fT; //hit good pulse time
21 Double_t fPI; //hit good pulse integral (used to do clustering)
22
23public:
24
26
27 THcNPSShowerHit(Int_t block_id, Int_t hRow, Int_t hCol, Double_t hX, Double_t hY, Double_t hZ,
28 Double_t hE, Double_t hT, Double_t hPI);
29
31 // cout << " hit destructed" << endl;
32 }
33
35 return fID;
36 }
37
39 return fCol;
40 }
41
43 return fRow;
44 }
45
47 return fX;
48 }
49
51 return fY;
52 }
53
55 return fZ;
56 }
57
59 return fE;
60 }
62 return fT;
63 }
65 return fPI;
66 }
67
68 bool isNeighbour(THcNPSShowerHit* hit1);
69 void show();
70 bool operator<(THcNPSShowerHit rhs) const;
71
72 // ClassDef(THcNPSShowerHit,0);
73};
74
75
76//____________________________________________________________________________
77
78// Container (collection) of hits and its iterator.
79//
80typedef set<THcNPSShowerHit*> THcNPSShowerHitSet;
81typedef THcNPSShowerHitSet::iterator THcNPSShowerHitIt;
82
84typedef THcNPSShowerCluster::iterator THcNPSShowerClusterIt;
85
86
87//______________________________________________________________________________
88
89//Alias for container of clusters and for its iterator
90//
91typedef vector<THcNPSShowerCluster*> THcNPSShowerClusterList;
92typedef THcNPSShowerClusterList::iterator THcNPSShowerClusterListIt;
93
94//______________________________________________________________________________
95
96
97
98
99#endif
int Int_t
double Double_t
THcNPSShowerCluster::iterator THcNPSShowerClusterIt
THcNPSShowerClusterList::iterator THcNPSShowerClusterListIt
vector< THcNPSShowerCluster * > THcNPSShowerClusterList
THcNPSShowerHitSet THcNPSShowerCluster
THcNPSShowerHitSet::iterator THcNPSShowerHitIt
set< THcNPSShowerHit * > THcNPSShowerHitSet
bool operator<(THcNPSShowerHit rhs) const
bool isNeighbour(THcNPSShowerHit *hit1)
STL namespace.