ATLAS Offline Software
Loading...
Searching...
No Matches
mm_readoutHandler.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
10#include <iostream>
11
12
15 : XMLHandler(s, c)
16{
17}
18
20 xercesc::DOMNode *t)
21{
22 micromegasHandler* mmHand = dynamic_cast<micromegasHandler*>
23 (c.GetHandlerStore().GetHandler("micromegas"));
24 if (!mmHand) std::abort();
25
27 // std::cout<<" this is mm_readoutHandler::Handle"<<MM->GetName()<<std::endl;
28
29 bool ret=true;
30 MM->roParameters.stripPitch = getAttributeAsDouble (c, t, "stripPitch", ret);
31 if (! ret) std::cout << "WARNING: stripPitch is missing" << std::endl;
32
33 MM->roParameters.gasThickness = getAttributeAsDouble (c, t, "gasThickness", ret);
34 if (! ret) std::cout << "WARNING: gasThickness is missing" << std::endl;
35
36 MM->roParameters.pcbThickness = getAttributeAsDouble (c, t, "pcbThickness", ret);
37 if (! ret) std::cout << "WARNING: pcbThickness is missing" << std::endl;
38
39 MM->roParameters.driftThickness = getAttributeAsDouble (c, t, "driftThickness", ret);
40 if (! ret) std::cout << "WARNING: driftThickness is missing" << std::endl;
41
42 MM->roParameters.stereoAngle = getAttributeAsVector (c, t, "stereoAngle", ret);
43 if (! ret) std::cout << "WARNING: stereoAngle is missing" << std::endl;
44
45 MM->roParameters.readoutSide = getAttributeAsIntVector (c, t, "readoutSide", ret);
46 if (! ret) std::cout << "WARNING: readoutSide is missing" << std::endl;
47
48 MM->roParameters.zpos = getAttributeAsDouble (c, t, "zPos", ret);
49 if (! ret) std::cout << "WARNING: zPos is missing" << std::endl;
50
51 MM->roParameters.distanceFromZAxis = getAttributeAsDouble (c, t, "distanceFromZAxis", ret);
52 if (! ret) std::cout << "WARNING: distanceFromZAxis is missing" << std::endl;
53
54 MM->roParameters.roLength = getAttributeAsDouble (c, t, "roLength", ret);
55 if (! ret) std::cout << "WARNING: roLength is missing" << std::endl;
56
57 MM->roParameters.activeBottomLength = getAttributeAsDouble (c, t, "activeBottomLength", ret);
58 if (! ret) std::cout << "WARNING: activeBottomLength is missing" << std::endl;
59
60 MM->roParameters.activeTopLength = getAttributeAsDouble (c, t, "activeTopLength", ret);
61 if (! ret) std::cout << "WARNING: activeTopLength is missing" << std::endl;
62
63 MM->roParameters.activeH = getAttributeAsDouble (c, t, "activeH", ret);
64 if (! ret) std::cout << "WARNING: activeH is missing" << std::endl;
65
66 MM->roParameters.minYPhiL = getAttributeAsDouble (c, t, "minYPhiL", ret);
67 if (! ret) std::cout << "WARNING: minYPhiL is missing" << std::endl;
68
69 MM->roParameters.minYPhiR = getAttributeAsDouble (c, t, "minYPhiR", ret);
70 if (! ret) std::cout << "WARNING: minYPhiR is missing" << std::endl;
71
72 MM->roParameters.maxYPhi = getAttributeAsDouble (c, t, "maxYPhi", ret);
73 if (! ret) std::cout << "WARNING: maxYPhi is missing" << std::endl;
74
75 MM->roParameters.dlStereoBottom = getAttributeAsDouble (c, t, "dlStereoBottom", ret);
76 if (! ret) std::cout << "WARNING: dlStereoBottom is missing" << std::endl;
77
78 MM->roParameters.dlStereoTop = getAttributeAsDouble (c, t, "dlStereoTop", ret);
79 if (! ret) std::cout << "WARNING: dlStereoTop is missing" << std::endl;
80
81 MM->roParameters.nMissedTopEta = getAttributeAsInt (c, t, "nMissedTopEta", ret);
82 if (! ret) std::cout << "WARNING: nMissedTopEta is missing" << std::endl;
83
84 MM->roParameters.nMissedBottomEta = getAttributeAsInt (c, t, "nMissedBottomEta", ret);
85 if (! ret) std::cout << "WARNING: nMissedBottomEta is missing" << std::endl;
86
87 MM->roParameters.nMissedTopStereo = getAttributeAsInt (c, t, "nMissedTopStereo", ret);
88 if (! ret) std::cout << "WARNING: nMissedTopStereo is missing" << std::endl;
89
90 MM->roParameters.nMissedBottomStereo = getAttributeAsInt (c, t, "nMissedBottomStereo", ret);
91 if (! ret) std::cout << "WARNING: nMissedBottomStereo is missing" << std::endl;
92
93 MM->roParameters.nRoutedTop = getAttributeAsInt (c, t, "nRoutedTop", ret);
94 if (! ret) std::cout << "WARNING: nRoutedTop is missing" << std::endl;
95
96 MM->roParameters.nRoutedBottom = getAttributeAsInt (c, t, "nRoutedBottom", ret);
97 if (! ret) std::cout << "WARNING: nRoutedBottom is missing" << std::endl;
98
99 MM->roParameters.tStrips = getAttributeAsInt (c, t, "totalStrips", ret);
100 if (! ret) std::cout << "WARNING: totalStrips is missing" << std::endl;
101
102
103}
@ MM
Definition RegSelEnums.h:38
int getAttributeAsInt(AGDDController &c, const xercesc::DOMNode *t, const std::string &) const
std::vector< double > getAttributeAsVector(AGDDController &c, const xercesc::DOMNode *t, const std::string &) const
std::vector< int > getAttributeAsIntVector(AGDDController &c, const xercesc::DOMNode *t, const std::string &) const
double getAttributeAsDouble(AGDDController &c, const xercesc::DOMNode *t, const std::string &) const
XMLHandler(const std::string &n, AGDDController &c)
MMDetectorDescription * GetMMCurrent()
mm_readoutHandler(const std::string &, AGDDController &c)
virtual void ElementHandle(AGDDController &c, xercesc::DOMNode *t) override