ATLAS Offline Software
LArHVIdMapping.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef LARHVIDMAPPING_H
6 #define LARHVIDMAPPING_H
7 
9 #include "Identifier/Identifier.h"
11 #include <vector>
12 #include <map>
13 
14 class LArElectrodeID;
15 class LArHVLineID;
16 class LArEM_ID;
17 class LArHEC_ID;
18 class LArFCAL_ID;
19 class CaloCell_ID;
20 
22 
23  friend class LArHVIdMappingAlg; //The conditions alg filling this object
24 
25  public:
26  LArHVIdMapping()=delete;
27  LArHVIdMapping(const CaloCell_ID* caloId, const LArHVLineID* hvId, const LArElectrodeID* elId);
28 
32  const HWIdentifier getLArHVLineID(HWIdentifier& electrodeId) const;
33 
34  // Returns a vector<electrodeID> given an input offlineID
35  //-------------------------------------------------------
36  void getElectrodeInCell(const Identifier& offId, std::vector<HWIdentifier> &elecId ) const;
37 
40  void getHVLineInCell( const Identifier& offId, std::vector<HWIdentifier> &hvlineId) const;
41 
42 
45  const std::vector<HWIdentifier>& getLArElectrodeIDvec(HWIdentifier& hvlineId) const;
46 
47 
50  int getCellModule(const Identifier& offId ) const;
51  int getCellEtaSector(const Identifier& offId ) const;
52  int getCellPhiSector(const Identifier& offId ) const;
53  std::pair<int,int> getCellElectrodeMinMax(const Identifier& offId) const;
54 
55  private:
56 
58  const LArEM_ID * m_emHelper ;
63 
64  std::map<HWIdentifier,HWIdentifier> m_electrode_hvline_map;
65  std::map<HWIdentifier,std::vector<HWIdentifier> > m_hvline_electrode_map;
66  const std::vector<HWIdentifier> m_invalid;
67 
68 };
69 
70 
71 
72 #include "AthenaKernel/CLASS_DEF.h"
73 CLASS_DEF( LArHVIdMapping, 260112632 , 1)
74 #include "AthenaKernel/CondCont.h"
75 CLASS_DEF( CondCont<LArHVIdMapping>, 92552832 , 1)
76 
77 #endif
LArHVIdMappingAlg
Definition: LArHVIdMappingAlg.h:15
LArHVIdMapping::m_electrode_hvline_map
std::map< HWIdentifier, HWIdentifier > m_electrode_hvline_map
Definition: LArHVIdMapping.h:64
LArHVIdMapping::getElectrodeInCell
void getElectrodeInCell(const Identifier &offId, std::vector< HWIdentifier > &elecId) const
Definition: LArHVIdMapping.cxx:113
LArHVIdMapping::getCellEtaSector
int getCellEtaSector(const Identifier &offId) const
Definition: LArHVIdMapping.cxx:720
LArHVIdMapping::m_hvline_electrode_map
std::map< HWIdentifier, std::vector< HWIdentifier > > m_hvline_electrode_map
Definition: LArHVIdMapping.h:65
LArHVIdMapping::m_hecHelper
const LArHEC_ID * m_hecHelper
Definition: LArHVIdMapping.h:59
LArElectrodeID
Helper for the Liquid Argon Calorimeter cell at the electrode level.
Definition: LArElectrodeID.h:101
LArHVIdMapping::m_electrodeHelper
const LArElectrodeID * m_electrodeHelper
Definition: LArHVIdMapping.h:62
LArHVIdMapping::getHVLineInCell
void getHVLineInCell(const Identifier &offId, std::vector< HWIdentifier > &hvlineId) const
Returns a vector<HVLineID> given an input offlineID.
Definition: LArHVIdMapping.cxx:207
LArHVIdMapping::m_fcalHelper
const LArFCAL_ID * m_fcalHelper
Definition: LArHVIdMapping.h:60
LArHVIdMapping::getCellModule
int getCellModule(const Identifier &offId) const
returns the Module of a given offId
Definition: LArHVIdMapping.cxx:398
LArHEC_ID
Helper class for LArHEC offline identifiers.
Definition: LArHEC_ID.h:85
LArHVIdMapping::getLArHVLineID
const HWIdentifier getLArHVLineID(HWIdentifier &electrodeId) const
Return the LArHVLineID corresponding to a given LArElectrodeId.
Definition: LArHVIdMapping.cxx:22
HWIdentifier
Definition: HWIdentifier.h:13
LArHVIdMapping::m_caloHelper
const CaloCell_ID * m_caloHelper
Definition: LArHVIdMapping.h:57
LArHVIdMapping::m_hvlineHelper
const LArHVLineID * m_hvlineHelper
Definition: LArHVIdMapping.h:61
LArHVIdMapping::m_emHelper
const LArEM_ID * m_emHelper
Definition: LArHVIdMapping.h:58
CaloCell_ID
Helper class for offline cell identifiers.
Definition: CaloCell_ID.h:34
HWIdentifier.h
IdentifierHash.h
LArHVIdMapping
Definition: LArHVIdMapping.h:21
CondCont< LArHVIdMapping >
LArHVIdMapping::getCellElectrodeMinMax
std::pair< int, int > getCellElectrodeMinMax(const Identifier &offId) const
Definition: LArHVIdMapping.cxx:1404
CLASS_DEF
#define CLASS_DEF(NAME, CID, VERSION)
associate a clid and a version to a type eg
Definition: Control/AthenaKernel/AthenaKernel/CLASS_DEF.h:64
LArHVIdMapping::m_invalid
const std::vector< HWIdentifier > m_invalid
Definition: LArHVIdMapping.h:66
LArHVIdMapping::getCellPhiSector
int getCellPhiSector(const Identifier &offId) const
Definition: LArHVIdMapping.cxx:1088
LArEM_ID
Helper class for LArEM offline identifiers.
Definition: LArEM_ID.h:118
LArFCAL_ID
Helper class for LArFCAL offline identifiers.
Definition: LArFCAL_ID.h:60
CLASS_DEF.h
macros to associate a CLID to a type
LArHVIdMapping::LArHVIdMapping
LArHVIdMapping()=delete
LArHVIdMapping::getLArElectrodeIDvec
const std::vector< HWIdentifier > & getLArElectrodeIDvec(HWIdentifier &hvlineId) const
Return a vector of LArElectrodeID corresponding to a given LArHVLineID.
Definition: LArHVIdMapping.cxx:83
Identifier
Definition: IdentifierFieldParser.cxx:14
LArHVLineID
Helper for the Liquid Argon Calorimeter High-Voltage identifiers.
Definition: LArHVLineID.h:48