Belle II Software development
CsiHit_v2.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#ifndef CsiHIT_V2_H
10#define CsiHIT_V2_H
11
12#include <simulation/dataobjects/SimHitBase.h>
13
14// ROOT
15#include <Math/Vector3D.h>
16
17namespace Belle2 {
31 class CsiHit_v2 : public SimHitBase {
32 public:
35 0), m_Erecdep(0) {;}
38 int CellId,
39 int TrackId,
40 int Pdg,
41 float FlightTime,
42 float Edep,
43 ROOT::Math::XYZVector Momentum,
44 ROOT::Math::XYZVector Position,
45 float Erecdep
46 ): SimHitBase(), m_CellId(CellId), m_TrackId(TrackId), m_Pdg(Pdg), m_FlightTime(FlightTime), m_Edep(Edep), m_Momentum(Momentum),
47 m_Position(Position), m_Erecdep(Erecdep)
48 {
49 }
50
51
54 void setCellId(int CellId) { m_CellId = CellId; }
55
58 void setTrackId(int TrackId) { m_TrackId = TrackId; }
59
62 void setPDGCode(int Pdg) { m_Pdg = Pdg; }
63
66 void setFlightTime(double FlightTime) { m_FlightTime = (float) FlightTime; }
67
70 void setEnergyDep(double Edep) { m_Edep = (float) Edep; }
71
74 void setMomentum(ROOT::Math::XYZVector Momentum) { m_Momentum = Momentum; }
75
78 void setPosIn(ROOT::Math::XYZVector Position) { m_Position = Position; }
79
82 void setPosition(ROOT::Math::XYZVector Position) { m_Position = Position; }
83
84
88 int getCellId() const { return m_CellId; }
89
93 int getTrackId() const { return m_TrackId; }
94
98 int getPDGCode() const { return m_Pdg; }
99
103 double getFlightTime() const { return (double)m_FlightTime; }
104
108 double getEnergyDep() const { return (double) m_Edep; }
109
113 double getEnergyRecDep() const { return (double) m_Erecdep; }
114
118 ROOT::Math::XYZVector getMomentum() const { return m_Momentum; }
119
123 ROOT::Math::XYZVector getPosIn() const { return m_Position; }
124
128 ROOT::Math::XYZVector getPosition() const { return m_Position; }
129
130
134 void shiftInTime(float delta) override { m_FlightTime += delta; }
135
136
137 private:
140 int m_Pdg;
142 float m_Edep;
143 ROOT::Math::XYZVector m_Momentum;
144 ROOT::Math::XYZVector m_Position;
145 float m_Erecdep;
147 ClassDefOverride(CsiHit_v2, 2)
148 };
149
151} // end namespace Belle2
152
153#endif
ClassCsiHit_v2 - Geant4 simulated hits in CsI crystals in BEAST.
Definition: CsiHit_v2.h:31
ROOT::Math::XYZVector m_Position
Position.
Definition: CsiHit_v2.h:144
int getPDGCode() const
Get Particle PDG (can be one of secondaries)
Definition: CsiHit_v2.h:98
void setEnergyDep(double Edep)
Set Deposit energy.
Definition: CsiHit_v2.h:70
int getTrackId() const
Get Track ID.
Definition: CsiHit_v2.h:93
int getCellId() const
Get Cell ID.
Definition: CsiHit_v2.h:88
int m_CellId
Cell ID.
Definition: CsiHit_v2.h:138
double getFlightTime() const
Get Flight time from IP.
Definition: CsiHit_v2.h:103
void setPDGCode(int Pdg)
Set Particle PDG (can be one of secondaries)
Definition: CsiHit_v2.h:62
void setPosition(ROOT::Math::XYZVector Position)
Set Position.
Definition: CsiHit_v2.h:82
double getEnergyRecDep() const
Get Deposit energy folded by resolution.
Definition: CsiHit_v2.h:113
CsiHit_v2(int CellId, int TrackId, int Pdg, float FlightTime, float Edep, ROOT::Math::XYZVector Momentum, ROOT::Math::XYZVector Position, float Erecdep)
Useful Constructor.
Definition: CsiHit_v2.h:37
void setCellId(int CellId)
Set Cell ID.
Definition: CsiHit_v2.h:54
double getEnergyDep() const
Get Deposit energy.
Definition: CsiHit_v2.h:108
float m_FlightTime
Flight time from IP.
Definition: CsiHit_v2.h:141
float m_Edep
Deposit energy.
Definition: CsiHit_v2.h:142
void setPosIn(ROOT::Math::XYZVector Position)
Set Position.
Definition: CsiHit_v2.h:78
void setMomentum(ROOT::Math::XYZVector Momentum)
Set Momentum.
Definition: CsiHit_v2.h:74
float m_Erecdep
Deposit energy reconstructed.
Definition: CsiHit_v2.h:145
void setTrackId(int TrackId)
Set Track ID.
Definition: CsiHit_v2.h:58
ROOT::Math::XYZVector getPosIn() const
Get Position.
Definition: CsiHit_v2.h:123
void setFlightTime(double FlightTime)
Set Flight time from IP.
Definition: CsiHit_v2.h:66
ROOT::Math::XYZVector getMomentum() const
Get Momentum.
Definition: CsiHit_v2.h:118
ROOT::Math::XYZVector getPosition() const
Get Position.
Definition: CsiHit_v2.h:128
void shiftInTime(float delta) override
Shift the SimHit in time (needed for beam background mixing)
Definition: CsiHit_v2.h:134
CsiHit_v2()
default constructor for ROOT
Definition: CsiHit_v2.h:34
ROOT::Math::XYZVector m_Momentum
Momentum.
Definition: CsiHit_v2.h:143
int m_TrackId
Track ID.
Definition: CsiHit_v2.h:139
int m_Pdg
Particle PDG (can be one of secondaries)
Definition: CsiHit_v2.h:140
Class SimHitBase - A common base for subdetector SimHits.
Definition: SimHitBase.h:28
Abstract base class for different kinds of events.