-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathTRestDetectorExperimentalReadout.h
69 lines (54 loc) · 2.01 KB
/
TRestDetectorExperimentalReadout.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
/**
* @file TRestDetectorExperimentalReadout.h
* @brief Defines the TRestDetectorExperimentalReadout class.
*/
#ifndef REST_TRESTDETECTOREXPERIMENTALREADOUT_H
#define REST_TRESTDETECTOREXPERIMENTALREADOUT_H
#include <TNamed.h>
#include <map>
#include "TRestDetectorExperimentalReadoutModule.h"
/**
* @class TRestDetectorExperimentalReadout
* @brief Represents an experimental readout detector.
* @inherits TNamed
* @author Luis Obis
*/
class TRestDetectorExperimentalReadout : public TNamed {
private:
std::vector<TRestDetectorExperimentalReadoutModule> fModules; /**< The modules of the detector. */
public:
/**
* @brief Constructs a TRestDetectorExperimentalReadout object.
*/
TRestDetectorExperimentalReadout() = default;
/**
* @brief Destructor for TRestDetectorExperimentalReadout.
*/
~TRestDetectorExperimentalReadout() override = default;
/**
* @brief Returns the number of modules in the detector.
* @return The number of modules.
*/
size_t GetNumberOfModules() { return fModules.size(); }
/**
* @brief Adds a module to the detector.
* @param module The module to add.
*/
void AddModule(const TRestDetectorExperimentalReadoutModule& module) { fModules.push_back(module); }
/**
* @brief Returns the modules of the detector.
* @return The modules.
*/
std::vector<const TRestDetectorExperimentalReadoutModule*> GetModules() const;
/**
* @brief Returns the modules that contain a given point.
* @param point The point to check.
* @return The modules containing the point.
*/
std::vector<const TRestDetectorExperimentalReadoutModule*> GetModulesForPoint(
const TVector3& point) const;
std::vector<const TRestDetectorExperimentalReadoutPixel*> GetPixelsForPoint(const TVector3& point) const;
std::vector<unsigned short> GetChannelsForPoint(const TVector3& point) const;
ClassDef(TRestDetectorExperimentalReadout, 1);
};
#endif // REST_TRESTDETECTOREXPERIMENTALREADOUT_H