File indexing completed on 2025-01-18 09:14:50
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015 #ifndef DETECTOR_DEVPGENERIC_H
0016 #define DETECTOR_DEVPGENERIC_H 1
0017
0018
0019 #include "Detector/DeVPSensor.h"
0020 #include "Detector/DeStatic.h"
0021 #include "Detector/DeIOV.h"
0022
0023
0024 namespace gaudi {
0025
0026
0027 namespace detail {
0028
0029
0030
0031
0032
0033
0034
0035
0036 class DeVPGenericStaticObject : public DeStaticObject {
0037 DE_CONDITIONS_TYPEDEFS;
0038
0039 enum { classID = 2 };
0040
0041 public:
0042 typedef std::vector<DeVPSensorStatic> Sensors;
0043 Sensors sensors;
0044
0045 public:
0046
0047 DE_CTORS_DEFAULT(DeVPGenericStaticObject);
0048
0049 virtual void initialize() override;
0050
0051 virtual void print(int indent, int flg) const override;
0052 };
0053 }
0054
0055
0056
0057
0058
0059
0060
0061
0062
0063 class DeVPGenericStaticElement
0064 : public dd4hep::Handle<detail::DeVPGenericStaticObject>
0065 {
0066 DE_CONDITIONS_TYPEDEFS;
0067 typedef Object static_t;
0068 typedef Object::Sensors Sensors;
0069 public:
0070
0071 DE_CTORS_HANDLE(DeVPGenericStaticElement,Base);
0072
0073 Object::Sensors& sensors() const { return access()->sensors; }
0074 };
0075
0076 typedef DetectorStaticElement<DeVPGenericStaticElement> DeVPGenericStatic;
0077
0078
0079 namespace detail {
0080
0081
0082
0083
0084
0085
0086
0087
0088 class DeVPGenericObject : public DeIOVObject {
0089 DE_CONDITIONS_TYPEDEFS;
0090
0091 public:
0092 typedef std::vector<DeVPSensor> Sensors;
0093 Sensors sensors;
0094
0095 public:
0096
0097 DE_CTORS_DEFAULT(DeVPGenericObject);
0098
0099 virtual void initialize() override;
0100
0101 virtual void print(int indent, int flg) const override;
0102 };
0103 }
0104
0105
0106
0107
0108
0109
0110
0111
0112
0113 class DeVPGenericElement : public dd4hep::Handle<detail::DeVPGenericObject> {
0114 DE_CONDITIONS_TYPEDEFS;
0115
0116 typedef Object iov_t;
0117 typedef Object::static_t static_t;
0118 typedef Object::Sensors Sensors;
0119
0120 public:
0121
0122 DE_CTORS_HANDLE(DeVPGenericElement,Base);
0123
0124 static_t& staticData() const { return access()->de_static; }
0125
0126 Object::Sensors& sensors() const { return access()->sensors; }
0127 };
0128
0129
0130 typedef DetectorElement<DeVPGenericElement> DeVPGeneric;
0131
0132 }
0133 #endif