1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
#ifndef TrackDeDxHits_H
#define TrackDeDxHits_H
#include <cstdint>
#include <vector>
namespace reco {
/**
* Class defining the dedx hits, i.e. track hits with only dedx need informations
*/
class DeDxHit {
public:
DeDxHit() {}
DeDxHit(float ch, float mom, float len, uint32_t rawDetId, float err = 0)
: m_charge(ch), m_momentum(mom), m_pathLength(len), m_rawDetId(rawDetId), m_error(err) {}
/// Return the angle and thick normalized, calibrated energy release
float charge() const { return m_charge; }
/// Return the momentum of the trajectory at the interaction point
float momentum() const { return m_momentum; }
/// Return the path length
float pathLength() const { return m_pathLength; }
/// Return the rawDetId
uint32_t rawDetId() const { return m_rawDetId; }
/// Return the error of the energy release
float error() const { return m_error; }
bool operator<(const DeDxHit &other) const { return m_charge < other.m_charge; }
private:
// Those data members should be "compressed" once usage
// of ROOT/reflex precision specifier will be available in CMSSW
float m_charge;
float m_momentum;
float m_pathLength;
uint32_t m_rawDetId;
float m_error;
};
typedef std::vector<DeDxHit> DeDxHitCollection;
} // namespace reco
#endif
|