CbmRoot
Loading...
Searching...
No Matches
CbmMuchModule.h
Go to the documentation of this file.
1/* Copyright (C) 2008-2020 St. Petersburg Polytechnic University, St. Petersburg
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Mikhail Ryzhinskiy [committer], Evgeny Kryshen, Florian Uhlig */
4
15#ifndef CBMMUCHMODULE_H
16#define CBMMUCHMODULE_H 1
17
18#include <Rtypes.h> // for THashConsistencyHolder, ClassDef
19#include <RtypesCore.h> // for Int_t, Double_t, Bool_t, Color_t, kTRUE
20#include <TPave.h> // for TPave
21#include <TVector3.h> // for TVector3
22
23#include <map> // for multimap
24#include <utility> // for pair
25
26class TClonesArray;
27
28class CbmMuchModule : public TPave {
29public:
41 CbmMuchModule(Int_t iStation, Int_t iLayer, Bool_t iSide, Int_t iModule, TVector3 position, TVector3 size,
42 Double_t cutRadius);
44 virtual ~CbmMuchModule() {}
45
47 Int_t GetDetectorId() const { return fDetectorId; }
48 Double_t GetCutRadius() const { return fCutRadius; }
49 TVector3 GetSize() const { return fSize; }
50 TVector3 GetPosition() const { return fPosition; }
51 Int_t GetDetectorType() const { return fDetectorType; }
52 TClonesArray* GetPoints() const { return fPoints; }
53 TClonesArray* GetHits() const { return fHits; }
54 TClonesArray* GetClusters() const { return fClusters; }
55
56 virtual Bool_t InitModule() { return kTRUE; }
57 virtual void DrawModule(Color_t) {}
58
59 void SetPoints(TClonesArray* points) { fPoints = points; }
60 void SetHits(TClonesArray* hits) { fHits = hits; }
61 void SetClusters(TClonesArray* clusters) { fClusters = clusters; }
63 void AddDigi(Double_t time, Int_t id) { fDigis.insert(std::pair<Double_t, Int_t>(time, id)); }
65 void ClearDigis() { fDigis.clear(); }
67 std::multimap<Double_t, Int_t> GetDigis() { return fDigis; }
68
69protected:
70 Int_t fDetectorId; // Unique detector ID
71 Int_t fDetectorType; // Detector type
72 Double_t fCutRadius; // Radius of the cut (if any, otherwise = -1.) [cm]
73 TVector3 fSize; // Size vector of the module (all dimensions in [cm])
74 TVector3 fPosition; // Location vector of the module center in global c.s. (all dimensions in [cm])
75 TClonesArray* fPoints;
76 TClonesArray* fHits;
77 TClonesArray* fClusters;
78 std::multimap<Double_t, Int_t> fDigis;
79
80private:
83
85};
86#endif
TClonesArray * points
static vector< vector< QAHit > > hits
static constexpr size_t size()
Definition KfSimdPseudo.h:2
CbmMuchModule & operator=(const CbmMuchModule &)
Int_t GetDetectorId() const
Double_t fCutRadius
void SetClusters(TClonesArray *clusters)
TVector3 GetSize() const
TClonesArray * GetPoints() const
void SetHits(TClonesArray *hits)
TVector3 fPosition
virtual void DrawModule(Color_t)
virtual ~CbmMuchModule()
virtual Bool_t InitModule()
TClonesArray * GetClusters() const
TClonesArray * fClusters
Double_t GetCutRadius() const
TClonesArray * fPoints
TClonesArray * GetHits() const
CbmMuchModule(const CbmMuchModule &)
std::multimap< Double_t, Int_t > GetDigis()
void SetPoints(TClonesArray *points)
TClonesArray * fHits
Int_t GetDetectorType() const
ClassDef(CbmMuchModule, 2)
void AddDigi(Double_t time, Int_t id)
TVector3 GetPosition() const
std::multimap< Double_t, Int_t > fDigis