ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Types | Private Member Functions | Private Attributes | List of all members
TBBeamQualityEMFractionTool Class Reference

#include <TBBeamQualityEMFractionTool.h>

Inheritance diagram for TBBeamQualityEMFractionTool:
Collaboration diagram for TBBeamQualityEMFractionTool:

Public Member Functions

 TBBeamQualityEMFractionTool (const std::string &type, const std::string &name, const IInterface *parent)
 
virtual ~TBBeamQualityEMFractionTool ()
 
virtual StatusCode initializeTool () override
 
virtual StatusCode accept (const std::vector< std::string > &) override
 
virtual StatusCode reject (const std::vector< std::string > &)
 
virtual StatusCode initialize () override
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Static Public Member Functions

static const InterfaceID & interfaceID ()
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Protected Attributes

const LArEM_IDm_emecID_help
 
const LArHEC_IDm_hecID_help
 
const LArFCAL_IDm_fcalID_help
 
float m_em_fraccut
 
std::vector< double > m_em_fracnumsamp
 
std::vector< double > m_em_fracdensamp
 
std::string m_em_fracnumdet
 
std::string m_em_fracdendet
 
std::map< float, float > m_Mlayer
 
float m_em_frac
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Definition at line 24 of file TBBeamQualityEMFractionTool.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ TBBeamQualityEMFractionTool()

TBBeamQualityEMFractionTool::TBBeamQualityEMFractionTool ( const std::string &  type,
const std::string &  name,
const IInterface *  parent 
)

Definition at line 22 of file TBBeamQualityEMFractionTool.cxx.

26  m_emecID_help(nullptr),
27  m_hecID_help(nullptr),
28  m_fcalID_help(nullptr),
29  m_em_frac(0)
30 {
31  declareInterface<TBBeamQualityTool>(this);
32  declareProperty("EM_fraccut",m_em_fraccut=0.2);
33  declareProperty("EM_fracnumsamp",m_em_fracnumsamp);
34  declareProperty("EM_fracdensamp",m_em_fracdensamp);
35  declareProperty("EM_fracnumdet",m_em_fracnumdet="none");
36  declareProperty("EM_fracdendet",m_em_fracdendet="none");
37 }

◆ ~TBBeamQualityEMFractionTool()

TBBeamQualityEMFractionTool::~TBBeamQualityEMFractionTool ( )
virtual

Definition at line 39 of file TBBeamQualityEMFractionTool.cxx.

40 { }

Member Function Documentation

◆ accept()

StatusCode TBBeamQualityEMFractionTool::accept ( const std::vector< std::string > &  particles)
overridevirtual

Implements TBBeamQualityTool.

Definition at line 142 of file TBBeamQualityEMFractionTool.cxx.

143 {//accept
144 
145  MsgStream log(msgSvc(),name());
146 
147  log << MSG::DEBUG
148  << "TBBeamQualityEMFractionTool: Started Accept"
149  << endmsg;
150 
151  StatusCode sc;
152 
153  log << MSG::DEBUG << "m_em_fracnumdet: "<<m_em_fracnumdet<<endmsg;
154  log << MSG::DEBUG << "m_em_fracdendet: "<<m_em_fracdendet<<endmsg;
155  log << MSG::DEBUG << " called for: "<<particles.size()<<" particles"<<endmsg;
156 
157  // setting up layers (h6)
158 
159  // setting tmp variables
160  // resetting the numerator and denominato to 0
161 
162  //long chan =0;
163  float numenergy=0;
164  float denenergy=0;
165  for (int i=0;i<500;++i) {
166  m_Mlayer[i]=0;
167  }
168 
169  //Accesing the CaloCellContainer
170  const CaloCellContainer* cellContainer = nullptr;
171 
172  sc = evtStore()->retrieve(cellContainer);
173  if (sc.isFailure()) {
174  log << MSG::ERROR << "couldn't get the calo cells from storegate" << endmsg;
175  log << MSG::ERROR << "here is what is in storegate: " << evtStore()->dump() << endmsg;
176  return StatusCode::FAILURE;
177  }
178 
179  for (const CaloCell* cell_ptr : *cellContainer) {
180 
181  //obtaining dde pointer
182  const CaloDetDescrElement* caloDDE_ptr = cell_ptr->caloDDE();
183 
184  //obtaining SubCalo
185  //const CaloCell_ID::SUBCALO subcalo = caloDDE_ptr->getSubCalo();
186 
187  //obtaining sampling (layer)
188  const CaloCell_ID::CaloSample sampling = caloDDE_ptr->getSampling();
189 
190  // This map will have the layers as an index and increment the energy
191  // Does this for ALL layers ( all detectors )
192 
193  m_Mlayer[sampling]+=cell_ptr->energy();
194 
195  } //iterating
196 
197  // picking out layers of interest and filling numerator and denominator energies.
198 
199  for (unsigned int i=0;i<m_em_fracnumsamp.size();++i) {
200  numenergy+=m_Mlayer.find(m_em_fracnumsamp[i])->second;
201  }
202 
203  for (unsigned int i=0;i<m_em_fracdensamp.size();++i) {
204  denenergy+=m_Mlayer.find(m_em_fracdensamp[i])->second;
205  }
206 
207  if (denenergy!=0) {
208  m_em_frac=numenergy/denenergy;
209 
210  if (m_em_frac<m_em_fraccut) {
211  return StatusCode::SUCCESS;
212  }
213  else {
214  return StatusCode::FAILURE;
215  }
216  }
217  else {
218  return StatusCode::FAILURE;
219  }
220 }//accept

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ initialize()

StatusCode TBBeamQualityTool::initialize ( )
overridevirtualinherited

Definition at line 30 of file TBBeamQualityTool.cxx.

32 {
33  return this->initializeTool();
34 }

◆ initializeTool()

StatusCode TBBeamQualityEMFractionTool::initializeTool ( )
overridevirtual

Reimplemented from TBBeamQualityTool.

Definition at line 42 of file TBBeamQualityEMFractionTool.cxx.

43 { //init
44  MsgStream log(msgSvc(),name());
45  log << MSG::DEBUG
46  << "initialize"
47  << endmsg;
48 
49  StatusCode sc;
50 
51  m_hecID_help = NULL;
52  m_emecID_help = NULL;
53  m_fcalID_help = NULL;
54 
55  /*
56  // retrieve detector description manager for LAr subsystem
57  const DataHandle<LArDetDescrManager> m_larMgr;
58  sc = detStore()->retrieve(m_larMgr);
59  if (sc.isFailure()) {
60  log << MSG::ERROR << "unable to retrieve LArDetDescrManager from detector store"<< endmsg;
61  return sc;
62  }
63 
64  //obtainine Identifier helpers
65  m_hecID_help = m_larMgr->get_hec_id();
66  if (!m_hecID_help) {
67  log << MSG::ERROR << "unable to obtain hec id " << endmsg;
68  return StatusCode::FAILURE;
69  }
70  m_emecID_help = m_larMgr->get_em_id();
71  if (!m_emecID_help) {
72  log << MSG::ERROR << "unable to obtain emec id " << endmsg;
73  return StatusCode::FAILURE;
74  }
75 
76  m_fcalID_help = m_larMgr->get_fcal_id();
77  if (!m_fcalID_help) {
78  log << MSG::ERROR << "unable to obtain fcal id " << endmsg;
79  return StatusCode::FAILURE;
80  }
81  */
82 
83 
84  // retrieve detector description manager for LAr subsystem
85  const CaloCell_ID* idHelper = nullptr;
86  ATH_CHECK( detStore()->retrieve (idHelper, "CaloCell_ID") );
87 
88  //obtainine Identifier helpers
89  m_hecID_help = idHelper->hec_idHelper();
90  if (!m_hecID_help) {
91  log << MSG::ERROR << "unable to obtain hec id " << endmsg;
92  return StatusCode::FAILURE;
93  }
94  m_emecID_help = idHelper->em_idHelper();
95  if (!m_emecID_help) {
96  log << MSG::ERROR << "unable to obtain emec id " << endmsg;
97  return StatusCode::FAILURE;
98  }
99 
100  m_fcalID_help = idHelper->fcal_idHelper();
101  if (!m_fcalID_help) {
102  log << MSG::ERROR << "unable to obtain fcal id " << endmsg;
103  return StatusCode::FAILURE;
104  }
105 
106 
107 
108  log<<MSG::DEBUG<<"Got to before p_toolSvc"<<endmsg;
109 
110  if (m_em_fracnumdet=="HEC") {
111  m_em_fracnumsamp.push_back(8);
112  m_em_fracnumsamp.push_back(9);
113  m_em_fracnumsamp.push_back(10);
114  }
115  if (m_em_fracdendet=="HEC") {
116  m_em_fracdensamp.push_back(8);
117  m_em_fracdensamp.push_back(9);
118  m_em_fracdensamp.push_back(10);
119  }
120  if (m_em_fracnumdet=="EMEC") {
121  m_em_fracnumsamp.push_back(6);
122  m_em_fracnumsamp.push_back(7);
123  }
124  if (m_em_fracdendet=="EMEC") {
125  m_em_fracdensamp.push_back(6);
126  m_em_fracdensamp.push_back(7);
127  }
128  if (m_em_fracnumdet=="FCAL") {
129  m_em_fracnumsamp.push_back(21);
130  m_em_fracnumsamp.push_back(22);
131  m_em_fracnumsamp.push_back(23);
132  }
133  if (m_em_fracdendet=="FCAL") {
134  m_em_fracdensamp.push_back(21);
135  m_em_fracdensamp.push_back(22);
136  m_em_fracdensamp.push_back(23);
137  }
138 
139  return StatusCode::SUCCESS;
140 }//init

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ interfaceID()

static const InterfaceID& TBBeamQualityTool::interfaceID ( )
inlinestaticinherited

Definition at line 42 of file TBBeamQualityTool.h.

42 { return IID_TBBeamQualityTool;}

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ reject()

StatusCode TBBeamQualityTool::reject ( const std::vector< std::string > &  particles)
virtualinherited

Definition at line 41 of file TBBeamQualityTool.cxx.

42 {
43  return this->accept(particles).isFailure()
44  ? StatusCode::SUCCESS
45  : StatusCode::FAILURE;
46 }

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_em_frac

float TBBeamQualityEMFractionTool::m_em_frac
protected

Definition at line 55 of file TBBeamQualityEMFractionTool.h.

◆ m_em_fraccut

float TBBeamQualityEMFractionTool::m_em_fraccut
protected

Definition at line 48 of file TBBeamQualityEMFractionTool.h.

◆ m_em_fracdendet

std::string TBBeamQualityEMFractionTool::m_em_fracdendet
protected

Definition at line 52 of file TBBeamQualityEMFractionTool.h.

◆ m_em_fracdensamp

std::vector<double> TBBeamQualityEMFractionTool::m_em_fracdensamp
protected

Definition at line 50 of file TBBeamQualityEMFractionTool.h.

◆ m_em_fracnumdet

std::string TBBeamQualityEMFractionTool::m_em_fracnumdet
protected

Definition at line 51 of file TBBeamQualityEMFractionTool.h.

◆ m_em_fracnumsamp

std::vector<double> TBBeamQualityEMFractionTool::m_em_fracnumsamp
protected

Definition at line 49 of file TBBeamQualityEMFractionTool.h.

◆ m_emecID_help

const LArEM_ID* TBBeamQualityEMFractionTool::m_emecID_help
protected

Definition at line 42 of file TBBeamQualityEMFractionTool.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_fcalID_help

const LArFCAL_ID* TBBeamQualityEMFractionTool::m_fcalID_help
protected

Definition at line 44 of file TBBeamQualityEMFractionTool.h.

◆ m_hecID_help

const LArHEC_ID* TBBeamQualityEMFractionTool::m_hecID_help
protected

Definition at line 43 of file TBBeamQualityEMFractionTool.h.

◆ m_Mlayer

std::map<float,float> TBBeamQualityEMFractionTool::m_Mlayer
protected

Definition at line 53 of file TBBeamQualityEMFractionTool.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files:
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
TBBeamQualityEMFractionTool::m_em_frac
float m_em_frac
Definition: TBBeamQualityEMFractionTool.h:55
CaloCell_ID::em_idHelper
const LArEM_ID * em_idHelper() const
access to EM idHelper
Definition: CaloCell_ID.h:63
TBBeamQualityTool::TBBeamQualityTool
TBBeamQualityTool(const std::string &name, const std::string &type, const IInterface *parent)
Definition: TBBeamQualityTool.cxx:21
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
CaloDetDescrElement
This class groups all DetDescr information related to a CaloCell. Provides a generic interface for al...
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:66
TBBeamQualityEMFractionTool::m_em_fracdendet
std::string m_em_fracdendet
Definition: TBBeamQualityEMFractionTool.h:52
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
TBBeamQualityEMFractionTool::m_em_fracdensamp
std::vector< double > m_em_fracdensamp
Definition: TBBeamQualityEMFractionTool.h:50
TBBeamQualityEMFractionTool::m_em_fracnumsamp
std::vector< double > m_em_fracnumsamp
Definition: TBBeamQualityEMFractionTool.h:49
TBBeamQualityTool::initializeTool
virtual StatusCode initializeTool()
Definition: TBBeamQualityTool.cxx:36
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
TBBeamQualityEMFractionTool::m_em_fraccut
float m_em_fraccut
Definition: TBBeamQualityEMFractionTool.h:48
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
CaloCell_ID::hec_idHelper
const LArHEC_ID * hec_idHelper() const
access to HEC idHelper
Definition: CaloCell_ID.h:69
AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:95
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
TBBeamQualityEMFractionTool::m_emecID_help
const LArEM_ID * m_emecID_help
Definition: TBBeamQualityEMFractionTool.h:42
TBBeamQualityEMFractionTool::m_fcalID_help
const LArFCAL_ID * m_fcalID_help
Definition: TBBeamQualityEMFractionTool.h:44
AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
StdJOSetup.msgSvc
msgSvc
Provide convenience handles for various services.
Definition: StdJOSetup.py:36
lumiFormat.i
int i
Definition: lumiFormat.py:85
CaloSampling::CaloSample
CaloSample
Definition: Calorimeter/CaloGeoHelpers/CaloGeoHelpers/CaloSampling.h:22
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
CaloCell_ID
Helper class for offline cell identifiers.
Definition: CaloCell_ID.h:34
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
TBBeamQualityTool::accept
virtual StatusCode accept(const std::vector< std::string > &)=0
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
TBBeamQualityEMFractionTool::m_em_fracnumdet
std::string m_em_fracnumdet
Definition: TBBeamQualityEMFractionTool.h:51
TBBeamQualityEMFractionTool::m_hecID_help
const LArHEC_ID * m_hecID_help
Definition: TBBeamQualityEMFractionTool.h:43
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
CaloCellContainer
Container class for CaloCell.
Definition: CaloCellContainer.h:55
a
TList * a
Definition: liststreamerinfos.cxx:10
h
CaloCell
Data object for each calorimeter readout cell.
Definition: CaloCell.h:57
CaloDetDescrElement::getSampling
CaloCell_ID::CaloSample getSampling() const
cell sampling
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:395
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
DEBUG
#define DEBUG
Definition: page_access.h:11
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
LArG4FSStartPointFilter.particles
list particles
Definition: LArG4FSStartPointFilter.py:84
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
TBBeamQualityEMFractionTool::m_Mlayer
std::map< float, float > m_Mlayer
Definition: TBBeamQualityEMFractionTool.h:53
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
CaloCell_ID::fcal_idHelper
const LArFCAL_ID * fcal_idHelper() const
access to FCAL idHelper
Definition: CaloCell_ID.h:75
fitman.k
k
Definition: fitman.py:528