13 #include "eformat/SourceIdentifier.h"
16 #include "GaudiKernel/IToolSvc.h"
19 using eformat::helper::SourceIdentifier;
24 ISvcLocator * pSvcLocator)
26 m_manager ( nullptr ),
27 m_idHelper ( nullptr ),
28 m_cabling ( nullptr ),
29 m_cablingTool_SR1_ECC ( nullptr ),
30 m_cablingTool_SR1 ( nullptr ),
31 m_cablingTool_TB ( nullptr ),
32 m_cablingTool_DC1 ( nullptr ),
33 m_cablingTool_DC2 ( nullptr ),
34 m_cablingTool_DC3 ( nullptr ),
36 m_numberOfStrawsInROD ( 0 ),
37 m_numberOfStrawsInBarrelROD ( 0 ),
38 m_shiftForLeftEndCapStraws ( 0 ),
39 m_shiftForLeftBarrelStraws ( 0 ),
40 m_shiftForRightBarrelStraws ( 0 ),
41 m_shiftForRightEndCapStraws ( 0 )
63 return StatusCode::FAILURE;
71 return StatusCode::FAILURE;
78 return StatusCode::FAILURE;
84 sc = service(
"ToolSvc",toolSvc);
88 return StatusCode::FAILURE;
96 toolType =
"TRT_FillCablingData_TB04";
100 ATH_MSG_ERROR(
" Can't get TRT_FillCablingData_TB04 tool " );
101 return StatusCode::FAILURE;
110 toolType =
"TRT_FillCablingData_DC3";
112 if( StatusCode::SUCCESS !=
116 return StatusCode::FAILURE;
125 toolType =
"TRT_FillCablingData_SR1";
130 return StatusCode::FAILURE;
138 toolType =
"TRT_FillCablingData_SR1_ECC";
140 if( StatusCode::SUCCESS !=
143 ATH_MSG_ERROR(
" Can't get TRT_FillCablingData_SR1_ECC tool " );
144 return StatusCode::FAILURE;
152 return StatusCode::FAILURE;
155 ATH_MSG_INFO(
"TRT_CablingSvc::initializiation finished" );
164 return StatusCode::SUCCESS;
170 void** ppvInterface )
172 if ( IIncidentListener::interfaceID().versionMatch(riid) )
174 *ppvInterface =
dynamic_cast<IIncidentListener*
>(
this);
180 return AthService::queryInterface(riid, ppvInterface);
183 return StatusCode::SUCCESS;
225 std::vector<uint32_t>
v;
231 subdetector,
const unsigned&
rod,
const int& bufferOffset,
245 int straw = bufferOffset;
246 if (subdetector == eformat::TRT_ENDCAP_A_SIDE)
254 if (subdetector == eformat::TRT_BARREL_A_SIDE)
262 if (subdetector == eformat::TRT_BARREL_C_SIDE)
294 ATH_MSG_FATAL(
"TRT_CablingSvc::getBufferOffset called in invalid case !" );
337 const std::vector<IdentifierHash>&
338 TRT_CablingSvc::getCollID(
uint32_t rob_id)
343 int TRT_CablingSvc::getNumStrawInROD(
uint32_t )
const
345 return m_numberOfStrawsInROD;
349 void TRT_CablingSvc::set_parameters()
351 int numberOfStrawsInROD;
352 int numberOfStrawsInBarrelROD;
353 int shiftForLeftEndCapStraws;
354 int shiftForLeftBarrelStraws;
355 int shiftForRightBarrelStraws;
356 int shiftForRightEndCapStraws;
357 int numberOfEndCapPhiSectors;
358 int numberOfIdentifierSectors;
364 numberOfStrawsInBarrelROD,
365 shiftForLeftEndCapStraws,
366 shiftForLeftBarrelStraws,
367 shiftForRightBarrelStraws,
368 shiftForRightEndCapStraws,
369 numberOfEndCapPhiSectors,
370 numberOfIdentifierSectors);
376 numberOfStrawsInBarrelROD,
377 shiftForLeftEndCapStraws,
378 shiftForLeftBarrelStraws,
379 shiftForRightBarrelStraws,
380 shiftForRightEndCapStraws,
381 numberOfEndCapPhiSectors,
382 numberOfIdentifierSectors);
391 m_numberOfEndCapPhiSectors = numberOfEndCapPhiSectors;
392 m_numberOfIdentifierSectors = numberOfIdentifierSectors;