BmnRoot
Loading...
Searching...
No Matches
BmnSsdSensor.h
Go to the documentation of this file.
1
10#ifndef BMNSSDSENSOR_H
11#define BMNSSDSENSOR_H 1
12
13
14#include <vector>
15#include <string>
16#include "BmnSsdAddress.h"
17#include "BmnSsdCluster.h"
18#include "BmnSsdElement.h"
20
21class TClonesArray;
22class TGeoPhysicalNode;
23class BmnEvent;
24class BmnLink;
25class BmnSsdModule;
26class BmnSsdPoint;
28
29
48{
49
50 public:
51
57 BmnSsdSensor(UInt_t address = 0, TGeoPhysicalNode* node = nullptr,
58 BmnSsdElement* mother = nullptr);
59
60
62 virtual ~BmnSsdSensor() { };
63
64
76 void CreateHit(Double_t xLocal, Double_t yLocal,
77 Double_t varX, Double_t varY, Double_t varXY,
78 BmnSsdCluster* clusterF, BmnSsdCluster* clusterB,
79 Double_t du = 0., Double_t dv = 0.);
80
81
89 virtual Int_t FindHits(std::vector<BmnSsdCluster*>& clusters,
90 TClonesArray* hitArray, BmnEvent* event,
91 Double_t dTime) = 0;
92
93
98 static UInt_t GetAddressFromName(TString name);
99
100
105
106
111
112
114 BmnSsdModule* GetModule() const;
115
116
120 TGeoPhysicalNode* GetNode() const {return fNode;}
121
122
128 virtual Bool_t Init() { return kTRUE; }
129
130
134
135
144 Int_t ProcessPoint(const BmnSsdPoint* point,
145 Double_t eventTime = 0., BmnLink* link = NULL);
146
147
151 void SetAddress(Int_t address) {
152 fAddress = address;
154 }
155
156
167 void SetConditions(Double_t vFD, Double_t vBias, Double_t temperature,
168 Double_t cCoupling, Double_t cInterstrip,
169 Double_t bX, Double_t bY, Double_t bZ) {
170 fConditions = new BmnSsdSensorConditions(vFD, vBias, temperature,
171 cCoupling, cInterstrip,
172 bX, bY, bZ);
173 }
174
175
179 void SetNode(TGeoPhysicalNode* node) { fNode = node; }
180
181
183 virtual std::string ToString() const = 0;
184
185
186 protected:
187
190 TClonesArray* fHits;
192
193
202 virtual Int_t CalculateResponse(BmnSsdSensorPoint* point) = 0;
203
204
206 BmnSsdSensor(const BmnSsdSensor&) = delete;
208
209
211
212};
213
214
215#endif
@ kSsdSensor
Data class for SSD clusters.
Class characterising one event by a collection of links (indices) to data objects,...
Definition BmnEvent.h:26
Data class for SSD clusters.
Class representing an element of the SSD setup.
TGeoPhysicalNode * fNode
Pointer to geometry.
Int_t fAddress
Unique element address.
Class representing an instance of a readout unit in the BMN-SSD.
Container for operating condition parameters of a sensor.
Container class for a local point in a SSD sensor.
Class representing an instance of a sensor in the BMN-SSD.
virtual ~BmnSsdSensor()
BmnSsdSensor(const BmnSsdSensor &)=delete
BmnLink * GetCurrentLink() const
virtual Bool_t Init()
Initialise the sensor, if needed.
void SetAddress(Int_t address)
Set sensor address.
virtual std::string ToString() const =0
void SetConditions(Double_t vFD, Double_t vBias, Double_t temperature, Double_t cCoupling, Double_t cInterstrip, Double_t bX, Double_t bY, Double_t bZ)
virtual Int_t FindHits(std::vector< BmnSsdCluster * > &clusters, TClonesArray *hitArray, BmnEvent *event, Double_t dTime)=0
TClonesArray * fHits
Output array for hits. Used in hit finding.
void CreateHit(Double_t xLocal, Double_t yLocal, Double_t varX, Double_t varY, Double_t varXY, BmnSsdCluster *clusterF, BmnSsdCluster *clusterB, Double_t du=0., Double_t dv=0.)
virtual Int_t CalculateResponse(BmnSsdSensorPoint *point)=0
///< Pointer to current event
const BmnSsdSensorConditions * GetConditions() const
void SetNode(TGeoPhysicalNode *node)
Set the physical node.
ClassDef(BmnSsdSensor, 2)
BmnLink * fCurrentLink
Link to currently processed MCPoint.
Int_t GetSensorId() const
BmnSsdModule * GetModule() const
BmnEvent * fEvent
static UInt_t GetAddressFromName(TString name)
Get the address from the sensor name (static)
TGeoPhysicalNode * GetNode() const
Int_t ProcessPoint(const BmnSsdPoint *point, Double_t eventTime=0., BmnLink *link=NULL)
BmnSsdSensorConditions * fConditions
Operating conditions.
BmnSsdSensor & operator=(const BmnSsdSensor &)=delete
UInt_t GetElementId(Int_t address, Int_t level)
Get the index of an element.