BmnRoot
26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Toggle main menu visibility
Loading...
Searching...
No Matches
BmnEcal.h
Go to the documentation of this file.
1
/*************************************************************************************
2
*
3
* Class BmnEcal
4
*
5
* Adopted for BMN by: Elena Litvinenko
6
* e-mail: litvin@nf.jinr.ru
7
* Version: 10-02-2016
8
* Updated: 09-08-2019 by Petr Alekseev <pnaleks@gmail.com>
9
*
10
************************************************************************************/
11
12
#ifndef BMNECAL_H
13
#define BMNECAL_H
14
15
#include "
BmnEcalGeoPar.h
"
16
#include "
BmnEcalPoint.h
"
17
#include "FairDetector.h"
18
#include "
TClonesArray.h
"
19
#include "
TLorentzVector.h
"
20
#include "
TVector3.h
"
21
22
class
BmnEcal
:
public
FairDetector
23
{
24
public
:
25
/** Default constructor **/
26
BmnEcal
();
27
28
/** Standard constructor.
29
*@param name detetcor name
30
*@param active sensitivity flag
31
**/
32
BmnEcal
(
const
char
* name,
Bool_t
active);
33
34
/** Destructor **/
35
virtual
~BmnEcal
();
36
37
/** Virtual method Initialize
38
** Initialises detector. Stores volume IDs for MUO detector and mirror.
39
**/
40
virtual
void
Initialize
();
41
42
/** Virtual method ProcessHits
43
**
44
** Defines the action to be taken when a step is inside the
45
** active volume. Creates BmnEcalPoints and BmnEcalMirrorPoints and adds
46
** them to the collections.
47
*@param vol Pointer to the active volume
48
**/
49
virtual
Bool_t
ProcessHits
(FairVolume* vol = 0);
50
51
/** Virtual method EndOfEvent
52
**
53
** If verbosity level is set, print hit collection at the
54
** end of the event and resets it afterwards.
55
**/
56
virtual
void
EndOfEvent
();
57
58
virtual
void
BeginEvent
();
59
/** Virtual method Register
60
**
61
** Registers the hit collection in the ROOT manager.
62
**/
63
virtual
void
Register
();
64
65
/** Accessor to the hit collection **/
66
virtual
TClonesArray
*
GetCollection
(
Int_t
iColl)
const
;
67
68
/** Virtual method Print
69
**
70
** Screen output of hit collection.
71
**/
72
virtual
void
Print
(
Option_t
*)
const
;
73
74
/** Virtual method Reset
75
**
76
** Clears the hit collection
77
**/
78
virtual
void
Reset
();
79
80
/** Virtual method CopyClones
81
**
82
** Copies the hit collection with a given track index offset
83
*@param cl1 Origin
84
*@param cl2 Target
85
*@param offset Index offset
86
**/
87
virtual
void
CopyClones
(
TClonesArray
* cl1,
TClonesArray
* cl2,
Int_t
offset);
88
89
/** Virtual method Construct geometry
90
**
91
**/
92
virtual
void
ConstructGeometry
();
93
94
virtual
Bool_t
CheckIfSensitive
(std::string name);
95
96
/** SetToFile
97
**
98
** Allows to disable writing the brunch into the output tree
99
*@param toFile if kFALSE, branch will NOT be saved to the tree
100
**/
101
void
SetToFile
(
Bool_t
toFile) {
fToFile
= toFile; }
102
103
BmnEcalPoint
*
AddHit
(
Int_t
trackID,
104
Int_t
detID,
105
Int_t
copyNo,
106
Int_t
copyNoMother,
107
TVector3
pos,
108
TVector3
mom,
109
Double_t
tof,
110
Double_t
length,
111
Double_t
eLoss);
112
113
private
:
114
Int_t
fTrackID
;
//! track index
115
Int_t
fVolumeID
;
//! volume id
116
TLorentzVector
fPos
;
//! position
117
TLorentzVector
fMom
;
//! momentum
118
Double32_t
fTime
;
//! time
119
Double32_t
fLength
;
//! length
120
Double32_t
fELoss
;
//! energy loss
121
122
TClonesArray
*
fEcalCollection
;
//! Hit collection
123
124
Bool_t
fToFile
=
kTRUE
;
//! if kFALSE, branch will NOT be saved to the tree
125
126
BmnEcal
(
const
BmnEcal
&) =
delete
;
127
BmnEcal
operator=
(
const
BmnEcal
&) =
delete
;
128
129
ClassDef
(
BmnEcal
, 3)
130
};
131
132
#endif
Bool_t
bool Bool_t
Int_t
int Int_t
Double32_t
double Double32_t
Double_t
double Double_t
kTRUE
constexpr Bool_t kTRUE
Option_t
const char Option_t
ClassDef
#define ClassDef(name, id)
TClonesArray.h
TLorentzVector.h
TVector3.h
BmnEcalPoint
Definition
BmnEcalPoint.h:18
BmnEcal::~BmnEcal
virtual ~BmnEcal()
Destructor.
Definition
BmnEcal.cxx:57
BmnEcal::BmnEcal
BmnEcal(const BmnEcal &)=delete
if kFALSE, branch will NOT be saved to the tree
BmnEcal::ProcessHits
virtual Bool_t ProcessHits(FairVolume *vol=0)
Virtual method ProcessHits.
Definition
BmnEcal.cxx:83
BmnEcal::CopyClones
virtual void CopyClones(TClonesArray *cl1, TClonesArray *cl2, Int_t offset)
Virtual method CopyClones.
Definition
BmnEcal.cxx:176
BmnEcal::Register
virtual void Register()
Virtual method Register.
Definition
BmnEcal.cxx:143
BmnEcal::SetToFile
void SetToFile(Bool_t toFile)
SetToFile.
Definition
BmnEcal.h:101
BmnEcal::BmnEcal
BmnEcal()
Default constructor.
Definition
BmnEcal.cxx:40
BmnEcal::fELoss
Double32_t fELoss
length
Definition
BmnEcal.h:120
BmnEcal::fMom
TLorentzVector fMom
position
Definition
BmnEcal.h:117
BmnEcal::fPos
TLorentzVector fPos
volume id
Definition
BmnEcal.h:116
BmnEcal::AddHit
BmnEcalPoint * AddHit(Int_t trackID, Int_t detID, Int_t copyNo, Int_t copyNoMother, TVector3 pos, TVector3 mom, Double_t tof, Double_t length, Double_t eLoss)
Definition
BmnEcal.cxx:250
BmnEcal::CheckIfSensitive
virtual Bool_t CheckIfSensitive(std::string name)
Definition
BmnEcal.cxx:240
BmnEcal::BeginEvent
virtual void BeginEvent()
Definition
BmnEcal.cxx:77
BmnEcal::fVolumeID
Int_t fVolumeID
track index
Definition
BmnEcal.h:115
BmnEcal::fTime
Double32_t fTime
momentum
Definition
BmnEcal.h:118
BmnEcal::Print
virtual void Print(Option_t *) const
Virtual method Print.
Definition
BmnEcal.cxx:158
BmnEcal::fEcalCollection
TClonesArray * fEcalCollection
energy loss
Definition
BmnEcal.h:122
BmnEcal::EndOfEvent
virtual void EndOfEvent()
Virtual method EndOfEvent.
Definition
BmnEcal.cxx:135
BmnEcal::fTrackID
Int_t fTrackID
Definition
BmnEcal.h:114
BmnEcal::GetCollection
virtual TClonesArray * GetCollection(Int_t iColl) const
Accessor to the hit collection.
Definition
BmnEcal.cxx:149
BmnEcal::operator=
BmnEcal operator=(const BmnEcal &)=delete
BmnEcal::fToFile
Bool_t fToFile
Hit collection.
Definition
BmnEcal.h:124
BmnEcal::fLength
Double32_t fLength
time
Definition
BmnEcal.h:119
BmnEcal::Initialize
virtual void Initialize()
Virtual method Initialize Initialises detector.
Definition
BmnEcal.cxx:67
BmnEcal::ConstructGeometry
virtual void ConstructGeometry()
Virtual method Construct geometry.
Definition
BmnEcal.cxx:192
BmnEcal::Reset
virtual void Reset()
Virtual method Reset.
Definition
BmnEcal.cxx:169
FairDetector
TClonesArray
TLorentzVector
TVector3
BmnEcalGeoPar.h
BmnEcalPoint.h
detectors
ecal
BmnEcal.h
Generated on
for BmnRoot by
1.17.0