ATLAS Offline Software
MergeHijingParsTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef MCTRUTHSIMALGS_MERGEHIJINGPARSTOOL_H
6 #define MCTRUTHSIMALGS_MERGEHIJINGPARSTOOL_H
7 
9 
11 #include "StoreGate/WriteHandle.h"
14 
15 #include "GaudiKernel/ServiceHandle.h"
16 
17 #include <string>
18 
27 public:
28  MergeHijingParsTool(const std::string& type,
29  const std::string& name,
30  const IInterface* parent);
31  virtual StatusCode initialize() override final;
34  virtual StatusCode prepareEvent(const EventContext& ctx, unsigned int nInputEvents) override final;
37  virtual StatusCode mergeEvent(const EventContext& ctx) override final;
40  virtual StatusCode processBunchXing(int bunchXing,
41  SubEventIterator bSubEvents,
42  SubEventIterator eSubEvents) override final;
45  virtual bool toProcess(int bunchXing) const override final;
49  virtual StatusCode processAllSubEvents(const EventContext& ctx) override final;
50 private:
51  ServiceHandle<PileUpMergeSvc> m_pMergeSvc{this, "PileUpMergeSvc", "PileUpMergeSvc", ""};
52  SG::WriteHandleKey<HijingEventParams> m_outputObjectKey{this, "HijingParamsKey", "Hijing_event_params", ""};
54  bool m_firstSubEvent{true};
55 };
56 #endif //MCTRUTHSIMALGS_MERGEHIJINGPARSTOOL_H
MergeHijingParsTool::processBunchXing
virtual StatusCode processBunchXing(int bunchXing, SubEventIterator bSubEvents, SubEventIterator eSubEvents) override final
called for each active bunch-crossing to process current SubEvents bunchXing is in ns
Definition: MergeHijingParsTool.cxx:28
HijingEventParams.h
MergeHijingParsTool::MergeHijingParsTool
MergeHijingParsTool(const std::string &type, const std::string &name, const IInterface *parent)
Definition: MergeHijingParsTool.cxx:7
MergeHijingParsTool::m_pMergeSvc
ServiceHandle< PileUpMergeSvc > m_pMergeSvc
Definition: MergeHijingParsTool.h:51
MergeHijingParsTool::m_outputObjectKey
SG::WriteHandleKey< HijingEventParams > m_outputObjectKey
Definition: MergeHijingParsTool.h:52
WriteHandle.h
Handle class for recording to StoreGate.
SG::WriteHandleKey< HijingEventParams >
MergeHijingParsTool::initialize
virtual StatusCode initialize() override final
Definition: MergeHijingParsTool.cxx:14
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
MergeHijingParsTool::toProcess
virtual bool toProcess(int bunchXing) const override final
return false if not interested in certain xing times (in ns) implemented by default in PileUpToolBase...
Definition: MergeHijingParsTool.cxx:85
MergeHijingParsTool::prepareEvent
virtual StatusCode prepareEvent(const EventContext &ctx, unsigned int nInputEvents) override final
called before the subevts loop.
Definition: MergeHijingParsTool.cxx:20
PileUpToolBase
Definition: PileUpToolBase.h:18
WriteHandleKey.h
Property holding a SG store/key/clid from which a WriteHandle is made.
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
MergeHijingParsTool::m_firstSubEvent
bool m_firstSubEvent
Definition: MergeHijingParsTool.h:54
SG::WriteHandle< HijingEventParams >
PileUpMergeSvc.h
the preferred mechanism to access information from the different event stores in a pileup job.
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
MergeHijingParsTool
an algorithm to propagate HijingPars to the overlay store
Definition: MergeHijingParsTool.h:26
SubEventIterator
std::vector< xAOD::EventInfo::SubEvent >::const_iterator SubEventIterator
Definition: IPileUpTool.h:22
MergeHijingParsTool::processAllSubEvents
virtual StatusCode processAllSubEvents(const EventContext &ctx) override final
Propagate the HijingParsections to the output StoreGate.
Definition: MergeHijingParsTool.cxx:91
PileUpToolBase.h
helper base class IPileUpTool::toProcess().
MergeHijingParsTool::mergeEvent
virtual StatusCode mergeEvent(const EventContext &ctx) override final
called at the end of the subevts loop.
Definition: MergeHijingParsTool.cxx:75
MergeHijingParsTool::m_outputObject
SG::WriteHandle< HijingEventParams > m_outputObject
Definition: MergeHijingParsTool.h:53
ServiceHandle< PileUpMergeSvc >