BmnRoot
Loading...
Searching...
No Matches
BmnBC.h
Go to the documentation of this file.
1/*************************************************************************************
2 *
3 * Class BmnBC
4 *
5 * Adopted for BMN by: Nikita Lashmanov, Andrey Dryuk
6 * e-mail: nikita10630@mail.ru, andredryuk@gmail.com
7 * Version: 20.12.2020
8 *
9 ************************************************************************************/
10
11#ifndef BMNBC_H
12#define BMNBC_H
13
14#include "FairDetector.h"
15#include "TClonesArray.h"
16#include "TVector3.h"
17#include "TLorentzVector.h"
18#include "FairDetector.h"
19#include "BmnBCGeoPar.h"
20#include "BmnBCPoint.h"
21#include "TVirtualMC.h"
22#include "TParticle.h"
23
24
25class BmnBC : public FairDetector
26{
27 public:
28
31
36 BmnBC(const char* name, Bool_t active);
37
39 virtual ~BmnBC();
40
41
45 virtual void Initialize();
46
54 virtual Bool_t ProcessHits(FairVolume* vol = 0);
55
61 virtual void EndOfEvent();
62
63 virtual void BeginEvent();
64
69 virtual void Register();
70
72 virtual TClonesArray* GetCollection(Int_t iColl) const;
73
78 virtual void Print(Option_t*) const;
79
84 virtual void Reset();
85
93 virtual void CopyClones(TClonesArray* cl1, TClonesArray* cl2, Int_t offset);
94
96 virtual void ConstructGeometry();
97
98 virtual void ConstructAsciiGeometry();
99 virtual Bool_t CheckIfSensitive(std::string name);
100
101 BmnBCPoint* AddHit(Int_t trackID, Int_t detID, Int_t copyNo,
102 TVector3 posIn, TVector3 posOut,
103 TVector3 momIn, TVector3 momOut,
104 Double_t tof, Double_t length, Double_t eLoss, Int_t fStat,
105 Bool_t isPrimary, Double_t charge, Int_t pdgId, Double_t lightYield,
106 Double_t timeIn, Double_t timeOut, Double_t lengthtrack);
107
108 private:
109 Int_t fTrackID;
110 Int_t fVolumeID;
111 //Int_t fEventID; //! event id
112 TVector3 fPosIn;
113 TVector3 fPosOut;
114 TVector3 fMomIn;
115 TVector3 fMomOut;
116 Double32_t fTime;
117 Double32_t fLength;
118 Double32_t fELoss;
119 Int_t fPosIndex;
120 Int_t volDetector;
121 Int_t fIsPrimary;
122 Double_t fCharge;
123 Int_t fPdgId;
124 Int_t fStation;
125 Float_t fLightYield;
126 TClonesArray* fBCCollection;
127 Double32_t fTimeIn;
128 Double32_t fTimeOut;
129 Double32_t fLengthtrack;
130
131
132 // reset all parameters
133 void ResetParameters();
134 BmnBC(const BmnBC&) = delete;
135 BmnBC operator=(const BmnBC&) = delete;
136
137 ClassDef(BmnBC,2)
138};
139
140
141//------------------------------------------------------------------------------------------------------------------------
142inline void BmnBC::ResetParameters()
143{
144 fTrackID = fVolumeID = 0;
145 fPosIn.SetXYZ(0.0, 0.0, 0.0);
146 fPosOut.SetXYZ(0.0, 0.0, 0.0);
147 fMomIn.SetXYZ(0.0, 0.0, 0.0);
148 fMomOut.SetXYZ(0.0, 0.0, 0.0);
149 fTime = fLength = fELoss = 0;
150 fTimeIn = fTimeOut = 0;
151 fLengthtrack = 0;
152 fPosIndex = 0;
153 fLightYield = 0;
154 };
155//------------------------------------------------------------------------------------------------------------------------
156
157#endif
Definition BmnBC.h:26
virtual void EndOfEvent()
virtual void Print(Option_t *) const
virtual Bool_t ProcessHits(FairVolume *vol=0)
virtual ~BmnBC()
virtual void Register()
virtual TClonesArray * GetCollection(Int_t iColl) const
virtual void ConstructAsciiGeometry()
virtual void Initialize()
virtual void ConstructGeometry()
virtual void Reset()
virtual void CopyClones(TClonesArray *cl1, TClonesArray *cl2, Int_t offset)
BmnBC(const char *name, Bool_t active)
virtual Bool_t CheckIfSensitive(std::string name)
virtual void BeginEvent()
BmnBCPoint * AddHit(Int_t trackID, Int_t detID, Int_t copyNo, TVector3 posIn, TVector3 posOut, TVector3 momIn, TVector3 momOut, Double_t tof, Double_t length, Double_t eLoss, Int_t fStat, Bool_t isPrimary, Double_t charge, Int_t pdgId, Double_t lightYield, Double_t timeIn, Double_t timeOut, Double_t lengthtrack)