ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
LArCalorimeter
LArGeoModel
LArHV
LArHV
EMBHVManager.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef LARHV_EMBHVMANAGER_H
6
#define LARHV_EMBHVMANAGER_H
7
8
#include "
LArHV/EMBHVModule.h
"
9
#include "
LArHV/EMBHVDescriptor.h
"
10
#include "
Identifier/HWIdentifier.h
"
11
#include <memory>
12
#include <functional>
13
14
#if !(defined(SIMULATIONBASE) || defined(GENERATIONBASE))
15
class
LArHVIdMapping
;
16
#endif
17
18
class
CondAttrListCollection
;
19
struct
EMBHVPayload
;
20
34
35
class
EMBHVManager
36
{
37
public
:
38
class
EMBHVData
39
{
40
public
:
41
static
constexpr
double
INVALID
= -99999;
42
class
Payload
;
43
EMBHVData
();
44
EMBHVData
(std::unique_ptr<Payload> payload);
45
EMBHVData
&
operator=
(
EMBHVData
&& other)
noexcept
;
46
~EMBHVData
();
47
bool
hvOn
(
const
EMBHVElectrode
& electrode,
const
int
& iGap)
const
;
48
double
voltage
(
const
EMBHVElectrode
& electrode,
const
int
& iGap)
const
;
49
double
current
(
const
EMBHVElectrode
& electrode,
const
int
& iGap)
const
;
50
int
hvLineNo
(
const
EMBHVElectrode
& electrode,
const
int
& iGap)
const
;
51
private
:
52
static
int
index
(
const
EMBHVElectrode
& electrode) ;
53
std::unique_ptr<Payload>
m_payload
;
54
};
55
56
EMBHVManager
();
57
~EMBHVManager
();
58
59
// Gets the descriptor. (Not generally for users but nothing to hide here).
60
const
EMBHVDescriptor
&
getDescriptor
()
const
;
61
62
unsigned
int
beginPhiIndex
()
const
;
63
unsigned
int
endPhiIndex
()
const
;
64
65
unsigned
int
beginEtaIndex
()
const
;
66
unsigned
int
endEtaIndex
()
const
;
67
68
static
unsigned
int
beginSectorIndex
() ;
69
static
unsigned
int
endSectorIndex
() ;
70
71
// Returns a high voltage module
72
const
EMBHVModule
&
getHVModule
(
unsigned
int
iSide
73
,
unsigned
int
iEta
74
,
unsigned
int
iPhi
75
,
unsigned
int
iSector)
const
;
76
77
// Begin/End side index (0=negative and 1= positive)
78
static
unsigned
int
beginSideIndex
() ;
79
static
unsigned
int
endSideIndex
() ;
80
81
// Get the database payload --- for use by simulation only
82
// (doesn't account for conditions changes)
83
EMBHVData
getDataSim
()
const
;
84
85
#if !(defined(SIMULATIONBASE) || defined(GENERATIONBASE))
86
EMBHVData
getData
(
const
LArHVIdMapping
& hvIdMapping,
87
const
std::vector<const CondAttrListCollection*>& attrLists)
const
;
88
// Get hvLine for an electrode
89
int
hvLineNo
(
const
EMBHVElectrode
& electrode
90
,
int
gap
91
,
const
LArHVIdMapping
* hvIdMapping
92
,
HWIdentifier
*hvlId=
nullptr
)
const
;
93
#endif
94
95
private
:
96
using
idfunc_t
= std::function<std::vector<HWIdentifier>(
HWIdentifier
)>;
97
EMBHVData
getData
(
const
idfunc_t
& idfunc,
98
const
std::vector<const CondAttrListCollection*>& attrLists)
const
;
99
100
EMBHVManager
(
const
EMBHVManager
& right) =
delete
;
101
EMBHVManager
&
operator=
(
const
EMBHVManager
& right) =
delete
;
102
103
friend
class
ImaginaryFriend
;
104
class
Clockwork
;
105
std::unique_ptr<const Clockwork>
m_c
;
106
};
107
108
#endif
EMBHVDescriptor.h
EMBHVModule.h
HWIdentifier.h
CondAttrListCollection
This class is a collection of AttributeLists where each one is associated with a channel number.
Definition
CondAttrListCollection.h:51
EMBHVDescriptor
Definition
EMBHVDescriptor.h:11
EMBHVElectrode
Definition
EMBHVElectrode.h:15
EMBHVManager::Clockwork
Definition
EMBHVManager.cxx:64
EMBHVManager::EMBHVData::Payload
Definition
EMBHVManager.cxx:96
EMBHVManager::EMBHVData
Definition
EMBHVManager.h:39
EMBHVManager::EMBHVData::INVALID
static constexpr double INVALID
Definition
EMBHVManager.h:41
EMBHVManager::EMBHVData::EMBHVData
EMBHVData()
EMBHVManager::EMBHVData::hvLineNo
int hvLineNo(const EMBHVElectrode &electrode, const int &iGap) const
Definition
EMBHVManager.cxx:142
EMBHVManager::EMBHVData::hvOn
bool hvOn(const EMBHVElectrode &electrode, const int &iGap) const
Definition
EMBHVManager.cxx:124
EMBHVManager::EMBHVData::m_payload
std::unique_ptr< Payload > m_payload
Definition
EMBHVManager.h:53
EMBHVManager::EMBHVData::voltage
double voltage(const EMBHVElectrode &electrode, const int &iGap) const
Definition
EMBHVManager.cxx:130
EMBHVManager::EMBHVData::~EMBHVData
~EMBHVData()
EMBHVManager::EMBHVData::operator=
EMBHVData & operator=(EMBHVData &&other) noexcept
Definition
EMBHVManager.cxx:112
EMBHVManager::EMBHVData::current
double current(const EMBHVElectrode &electrode, const int &iGap) const
Definition
EMBHVManager.cxx:136
EMBHVManager::beginPhiIndex
unsigned int beginPhiIndex() const
Definition
EMBHVManager.cxx:174
EMBHVManager::endEtaIndex
unsigned int endEtaIndex() const
Definition
EMBHVManager.cxx:189
EMBHVManager::operator=
EMBHVManager & operator=(const EMBHVManager &right)=delete
EMBHVManager::endSectorIndex
static unsigned int endSectorIndex()
Definition
EMBHVManager.cxx:204
EMBHVManager::beginEtaIndex
unsigned int beginEtaIndex() const
Definition
EMBHVManager.cxx:184
EMBHVManager::EMBHVManager
EMBHVManager(const EMBHVManager &right)=delete
EMBHVManager::EMBHVManager
EMBHVManager()
Definition
EMBHVManager.cxx:161
EMBHVManager::getDescriptor
const EMBHVDescriptor & getDescriptor() const
Definition
EMBHVManager.cxx:169
EMBHVManager::idfunc_t
std::function< std::vector< HWIdentifier >(HWIdentifier)> idfunc_t
Definition
EMBHVManager.h:96
EMBHVManager::beginSectorIndex
static unsigned int beginSectorIndex()
Definition
EMBHVManager.cxx:199
EMBHVManager::getHVModule
const EMBHVModule & getHVModule(unsigned int iSide, unsigned int iEta, unsigned int iPhi, unsigned int iSector) const
Definition
EMBHVManager.cxx:194
EMBHVManager::hvLineNo
int hvLineNo(const EMBHVElectrode &electrode, int gap, const LArHVIdMapping *hvIdMapping, HWIdentifier *hvlId=nullptr) const
Definition
EMBHVManager.cxx:352
EMBHVManager::getData
EMBHVData getData(const LArHVIdMapping &hvIdMapping, const std::vector< const CondAttrListCollection * > &attrLists) const
Definition
EMBHVManager.cxx:343
EMBHVManager::getDataSim
EMBHVData getDataSim() const
Definition
EMBHVManager.cxx:324
EMBHVManager::endPhiIndex
unsigned int endPhiIndex() const
Definition
EMBHVManager.cxx:179
EMBHVManager::~EMBHVManager
~EMBHVManager()
EMBHVManager::beginSideIndex
static unsigned int beginSideIndex()
Definition
EMBHVManager.cxx:209
EMBHVManager::ImaginaryFriend
friend class ImaginaryFriend
Definition
EMBHVManager.h:103
EMBHVManager::m_c
std::unique_ptr< const Clockwork > m_c
Definition
EMBHVManager.h:105
EMBHVManager::endSideIndex
static unsigned int endSideIndex()
Definition
EMBHVManager.cxx:214
EMBHVModule
Describes one HV Module within the EMB.
Definition
EMBHVModule.h:22
HWIdentifier
Definition
HWIdentifier.h:13
LArHVIdMapping
Definition
LArHVIdMapping.h:21
index
Definition
index.py:1
EMBHVPayload
Definition
EMBHVPayload.h:8
Generated on
for ATLAS Offline Software by
1.17.0