Hall-D Software  alpha
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DrcLutNode.h
Go to the documentation of this file.
1 // -----------------------------------------
2 // DrcLutNode.h - Container for look-up table
3 //
4 // created on: 29.11.2017
5 // initial athor: r.dzhygadlo at gsi.de
6 
7 #ifndef DrcLutNode_h
8 #define DrcLutNode_h 1
9 
10 #include "TObject.h"
11 #include "TClonesArray.h"
12 #include "TVector3.h"
13 #include <vector>
14 #include <iostream>
15 
16 class DrcLutNode : public TObject {
17 
18 public:
19 
20  // Default constructor
21  DrcLutNode ();
22 
23  // Standard constructors
24  DrcLutNode (Int_t detectorId);
25 
26  // Copy constructor
27  //DrcLutNode (DrcLutNode& node) { *this = node; }
28 
29  // Modifiers
30  void AddEntry(Int_t lutId, Int_t nodeId, TVector3 dir, Long64_t pathid, Int_t nrefl, Double_t time, TVector3 hitpos, TVector3 digipos, Double_t weight=1);
31  void AddEntry(Int_t lutId, Int_t nodeId, TVector3 dir, Long64_t pathid, Int_t nrefl, Double_t time, TVector3 hitpos, TVector3 digipos, Double_t weight,
32  TVector3 d1,TVector3 d2,TVector3 d3,TVector3 d4,TVector3 d5,TVector3 d6,TVector3 d7,TVector3 d8);
33  void SetDigiPos(TVector3 pos){fDigiPos = pos;}
34 
35  // Accessors
36  Int_t Entries() { return fSize; }
37  Double_t GetLutId() { return fLutId; }
38  Double_t GetDetectorId() { return fDetectorId; }
39  TVector3 GetEntry(Int_t entry) { return fNodeArray[entry]; }
40  //TVector3 GetEntryCs(Int_t entry, Int_t side) { return fNodeArrayCs[side][entry]; }
41  Long64_t GetPathId(Int_t entry){ return fPathIdArray[entry]; }
42  Double_t GetWeight(Int_t entry){ return fWeightArray[entry]; }
43  Int_t GetNRefl(Int_t entry){ return fNReflArray[entry]; }
44  Double_t GetTime(Int_t entry){ return fTimeArray[entry]; }
45  TVector3 GetHitPos(Int_t entry){ return fHitPos[entry]; }
46  TVector3 GetDigiPos(){ return fDigiPos; }
47 
48 protected:
49 
50  Int_t fLutId;
51  Int_t fDetectorId;
52  Int_t fSize;
53  TVector3 fDigiPos;
54 
55  std::vector<TVector3> fNodeArray;
56  //std::vector<TVector3> fNodeArrayCs[9];
57  std::vector<TVector3> fHitPos;
58  std::vector<Long64_t> fPathIdArray;
59  std::vector<Double_t> fWeightArray;
60  std::vector<Int_t> fNReflArray;
61  std::vector<Double_t> fTimeArray;
62 
63 protected:
64  ClassDef(DrcLutNode, 1);
65 
66 };
67 
68 #endif
TVector3 GetDigiPos()
Definition: DrcLutNode.h:46
Int_t fSize
Definition: DrcLutNode.h:52
std::vector< Double_t > fTimeArray
Definition: DrcLutNode.h:61
Int_t GetNRefl(Int_t entry)
Definition: DrcLutNode.h:43
void SetDigiPos(TVector3 pos)
Definition: DrcLutNode.h:33
Int_t fLutId
Definition: DrcLutNode.h:50
std::vector< TVector3 > fHitPos
Definition: DrcLutNode.h:57
std::vector< TVector3 > fNodeArray
Definition: DrcLutNode.h:55
Double_t GetTime(Int_t entry)
Definition: DrcLutNode.h:44
void AddEntry(Int_t lutId, Int_t nodeId, TVector3 dir, Long64_t pathid, Int_t nrefl, Double_t time, TVector3 hitpos, TVector3 digipos, Double_t weight=1)
Definition: DrcLutNode.cc:14
TVector3 GetHitPos(Int_t entry)
Definition: DrcLutNode.h:45
Long64_t GetPathId(Int_t entry)
Definition: DrcLutNode.h:41
Double_t GetDetectorId()
Definition: DrcLutNode.h:38
std::vector< Long64_t > fPathIdArray
Definition: DrcLutNode.h:58
std::vector< Int_t > fNReflArray
Definition: DrcLutNode.h:60
ClassDef(DrcLutNode, 1)
std::vector< Double_t > fWeightArray
Definition: DrcLutNode.h:59
Int_t fDetectorId
Definition: DrcLutNode.h:51
TVector3 fDigiPos
Definition: DrcLutNode.h:53
Int_t Entries()
Definition: DrcLutNode.h:36
Double_t GetLutId()
Definition: DrcLutNode.h:37
TDirectory * dir
Definition: bcal_hist_eff.C:31
TVector3 GetEntry(Int_t entry)
Definition: DrcLutNode.h:39
Double_t GetWeight(Int_t entry)
Definition: DrcLutNode.h:42