ATLAS Offline Software
CountHepMC.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef XAOD_ANALYSIS
6 
7 #ifndef EVGENPRODTOOLS_COUNTHEPMC_H
8 #define EVGENPRODTOOLS_COUNTHEPMC_H
9 
13 
22 class CountHepMC : public GenBase {
23 public:
24 
25  CountHepMC(const std::string& name, ISvcLocator* pSvcLocator);
26 
27  virtual StatusCode initialize() override;
28  virtual StatusCode execute() override;
29  virtual StatusCode finalize() override;
30 
31 private:
32 
34  "StoreGateSvc/MetaDataStore", name()};
35  int m_nPass{0};
36  int m_nCount;
37 
38  long long int m_firstEv;
40 
41  bool m_corHepMC;
42  bool m_corEvtID;
45  std::string m_inputKeyName;
46 
47  SG::ReadHandleKey<xAOD::EventInfo> m_inputEvtInfoKey { this, "InputEventInfo", "TMPEvtInfo", "ReadHandleKey for Input xAOD::EventInfo" };
48  SG::WriteHandleKey<xAOD::EventInfo> m_outputEvtInfoKey{ this, "OutputEventInfo", "EventInfo", "WriteHandleKey for Output xAOD::EventInfo" };
49 
50  SG::ReadDecorHandleKey<xAOD::EventInfo> m_mcWeightsKey {this, "mcEventWeightsKey", "TMPEvtInfo.mcEventWeights", "Decoration for MC Event Weights"};
51 
52 };
53 
54 
55 #endif
56 
57 #endif
CountHepMC::m_outputEvtInfoKey
SG::WriteHandleKey< xAOD::EventInfo > m_outputEvtInfoKey
Definition: CountHepMC.h:48
ReadDecorHandleKey.h
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
CountHepMC::m_inputKeyName
std::string m_inputKeyName
Definition: CountHepMC.h:45
CountHepMC::CountHepMC
CountHepMC(const std::string &name, ISvcLocator *pSvcLocator)
Definition: CountHepMC.cxx:27
SG::ReadHandleKey< xAOD::EventInfo >
CountHepMC::m_corRunNumber
bool m_corRunNumber
Definition: CountHepMC.h:43
CountHepMC::execute
virtual StatusCode execute() override
Definition: CountHepMC.cxx:55
CountHepMC::initialize
virtual StatusCode initialize() override
Definition: CountHepMC.cxx:40
GenBase
Base class for common behaviour of MC truth algorithms.
Definition: GenBase.h:47
SG::WriteHandleKey< xAOD::EventInfo >
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
GenBase.h
CountHepMC::m_nPass
int m_nPass
Definition: CountHepMC.h:35
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
EventInfo.h
CountHepMC::m_mcWeightsKey
SG::ReadDecorHandleKey< xAOD::EventInfo > m_mcWeightsKey
Definition: CountHepMC.h:50
CountHepMC
Count the number of events to pass all algorithms/filters.
Definition: CountHepMC.h:22
CountHepMC::m_inputEvtInfoKey
SG::ReadHandleKey< xAOD::EventInfo > m_inputEvtInfoKey
Definition: CountHepMC.h:47
CountHepMC::m_metaDataStore
ServiceHandle< StoreGateSvc > m_metaDataStore
Definition: CountHepMC.h:33
CountHepMC::m_nCount
int m_nCount
Definition: CountHepMC.h:36
CountHepMC::finalize
virtual StatusCode finalize() override
Definition: CountHepMC.cxx:276
SG::ReadDecorHandleKey
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
Definition: StoreGate/StoreGate/ReadDecorHandleKey.h:85
CountHepMC::m_firstEv
long long int m_firstEv
Definition: CountHepMC.h:38
CountHepMC::m_newRunNumber
int m_newRunNumber
Definition: CountHepMC.h:39
CountHepMC::m_copyRunNumber
bool m_copyRunNumber
Definition: CountHepMC.h:44
CountHepMC::m_corEvtID
bool m_corEvtID
Definition: CountHepMC.h:42
CountHepMC::m_corHepMC
bool m_corHepMC
Definition: CountHepMC.h:41
ServiceHandle< StoreGateSvc >