|
ATLAS Offline Software
|
Definition of the TileDetectorFactoryLite class. The TileDetectorFactoryLite is invoked by the TileDetectorTool when the GeoModel description of Tile calorimeter is built from the SQLite database It also builds readout geometry (coming soon).
More...
#include <TileDetectorFactoryLite.h>
Definition of the TileDetectorFactoryLite class. The TileDetectorFactoryLite is invoked by the TileDetectorTool when the GeoModel description of Tile calorimeter is built from the SQLite database It also builds readout geometry (coming soon).
- Author
- Riccardo Maria BIANCHI ricca.nosp@m.rdo..nosp@m.maria.nosp@m..bia.nosp@m.nchi@.nosp@m.cern.nosp@m..ch , Aug 2021
Updates:
Definition at line 41 of file TileDetectorFactoryLite.h.
◆ TileDetectorFactoryLite()
◆ ~TileDetectorFactoryLite()
TileDetectorFactoryLite::~TileDetectorFactoryLite |
( |
| ) |
|
◆ create()
void TileDetectorFactoryLite::create |
( |
GeoPhysVol * |
world | ) |
|
|
virtual |
Creation of Tile geometry.
Definition at line 61 of file TileDetectorFactoryLite.cxx.
63 (*m_log) << MSG::INFO <<
" Entering TileDetectorFactoryLite::create()" <<
endmsg;
77 (*m_log) << MSG::INFO <<
"Getting auxiliary data from SQLite..." <<
endmsg;
80 (*m_log) <<
MSG::DEBUG <<
"data rows in the 'TileReadoutData' RecordSet: " << tileReadoutDataRecordSet->size() <<
endmsg;
82 double barrelPeriodThickness = 0., extendedPeriodThickness = 0.;
83 if (tileReadoutDataRecordSet->size()>0) {
84 if ( (*tileReadoutDataRecordSet)[0]->getString(
"NAME") ==
"barrelPeriodThickness" ) {
85 barrelPeriodThickness = (*tileReadoutDataRecordSet)[0]->getDouble(
"VALUE");
87 std::string errMsg =
"barrelPeriodThickness not found in position [0] in the TileReadoutData' RecordSet!!!";
88 (*m_log) << MSG::ERROR << errMsg <<
endmsg;
89 throw std::runtime_error(errMsg);
91 if ( (*tileReadoutDataRecordSet)[1]->getString(
"NAME") ==
"extendedPeriodThickness" ) {
92 extendedPeriodThickness = (*tileReadoutDataRecordSet)[1]->getDouble(
"VALUE");
94 std::string errMsg =
"extendedPeriodThickness not found in position [1] in the TileReadoutData' RecordSet!!!";
95 (*m_log) << MSG::ERROR << errMsg <<
endmsg;
96 throw std::runtime_error(errMsg);
99 std::string
errorMsg =
"The 'TileReadoutData' recordSet is empty!!!";
103 (*m_log) <<
MSG::DEBUG <<
"barrelPeriodThickness: " << barrelPeriodThickness <<
", extendedPeriodThickness: " << extendedPeriodThickness <<
endmsg;
114 int nModulesInSection[6] = {0,0,0,0,0,0};
115 double zShiftInSection[6] = {0.0,0.0,0.0,0.0,0.0,0.0,};
120 for (
int EnvCounter = 0; EnvCounter < NumberOfEnv; ++EnvCounter) {
129 <<
" EnvCounter is " << EnvCounter
130 <<
" EnvType is " << EnvType
135 if (EnvType == 1 || EnvType == 0) {
136 nModulesInSection[0] = nModulesInSection[1] = NumberOfMod;
137 zShiftInSection[0] = zShiftInSection[1] = Zshift;
138 }
else if (EnvType>0 and EnvType < 6) {
139 nModulesInSection[EnvType] = NumberOfMod;
140 zShiftInSection[EnvType] = Zshift;
151 int side[6] = {0,1,0,1,0,1};
153 (*m_log) <<
MSG::DEBUG <<
"Loop over Tile detector regions, and call computeCellDim() when needed..." <<
endmsg;
154 for (
int ii=0; ii<6; ++ii) {
156 (*m_log) <<
MSG::DEBUG <<
"ii: " << ii <<
", region: " << dete[ii] <<
endmsg;
159 (*m_log) <<
MSG::DEBUG <<
"ii: " << ii <<
", region: " << dete[ii] <<
" --> calling computeCellDim()..." <<
endmsg;
162 zShiftInSection[ii+1],
163 zShiftInSection[ii]);
166 (*m_log) <<
MSG::DEBUG <<
"Get TileDetDescriptor and call fillDescriptor()..." <<
endmsg;
171 nModulesInSection[ii],
172 zShiftInSection[ii]);
174 (*m_log) <<
MSG::DEBUG <<
"Get an Identifier for the region and add it to the detectorManager..." <<
endmsg;
176 descriptor->
set(idRegion);
183 GeoVolumeCursor
cursor(world);
185 std::string volName =
cursor.getName();
186 if (volName.compare(0,4,
"Tile")==0) {
187 (*m_log) <<
MSG::DEBUG <<
"Adding vol '" << volName <<
"' to detManager" <<
endmsg;
193 (*m_log) <<
MSG::DEBUG <<
"Tile geometry from SQLite has been created." <<
endmsg;
◆ getDetectorManager()
◆ m_detectorManager
◆ m_log
MsgStream* TileDetectorFactoryLite::m_log |
|
private |
◆ m_paramsSvc
◆ m_switches
◆ m_verbose
bool TileDetectorFactoryLite::m_verbose |
|
private |
The documentation for this class was generated from the following files:
int SetCurrentEnvByIndex(unsigned int envelope)
MsgStream * m_log
Get message SVC.
virtual IRDBRecordset_ptr getRecordsetPtr(const std::string &node, const std::string &tag, const std::string &tag2node="", const std::string &connName="ATLASDD")=0
Provides access to the Recordset object containing HVS-tagged data.
void addTreeTop(PVConstLink)
bool testBeam
setting up testbeam geometry or ATLAS geometry
int GetNumberOfEnv() const
#define TILE_REGION_EXTENDED
TileSwitches m_switches
all switches
void fillDescriptor(TileDetDescriptor *&descriptor, unsigned int detector, int side, bool testbeam, bool addPlates, unsigned int nphi, float zshift)
Readout Descriptor parameters are the following:
Identifier region_id(int index) const
build single region, module, tower, cell, pmt, adc identifiers
void set(const Identifier &id)
Helper class for TileCal offline identifiers.
double GetEnvZShift() const
TileDetDescrManager * m_detectorManager
Detector pointer to TileDetDescrManager.
std::shared_ptr< IRDBRecordset > IRDBRecordset_ptr
#define TILE_REGION_CENTRAL
bool addPlatesToCell
calculate cell volumes with or without front-plates and end-plates
IRDBAccessSvc * m_paramsSvc
Pointer to an instance of the RDBAccessSvc to get parameters from the SQLite file.
void setBarrelPeriodThickness(double val)
void add(TileDetDescrRegion *region)
This class holds one or more material managers and makes them storeable, under StoreGate.
void setExtendedPeriodThickness(double val)
TileDddbManager * getDbManager() const
void computeCellDim(TileDetDescrManager *&manager, int detector, bool addPlates, float zShiftPos, float zShiftNeg)
Cell dimension parameters are the following:
bool m_verbose
Flag for activation verbose level for debugging.
This class provides access to constants in the Geometry DB.
int GetEnvNModules() const
const TileID * get_id() const