ATLAS Offline Software
Loading...
Searching...
No Matches
EventInfoCnvTool.h
Go to the documentation of this file.
1// Dear emacs, this is -*- c++ -*-
2
3/*
4 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
5*/
6
7#ifndef XAODEVENTINFOCNV_EVENTINFOCNVTOOL_H
8#define XAODEVENTINFOCNV_EVENTINFOCNVTOOL_H
9
10// Gaudi/Athena include(s):
12#include "GaudiKernel/ServiceHandle.h"
13#include "GaudiKernel/ToolHandle.h"
14
15#if !defined(XAOD_ANALYSIS) && !defined(GENERATIONBASE)
17#endif // not XAOD_ANALYSIS or GENERATIONBASE
18
19#if !defined(XAOD_ANALYSIS) && !defined(GENERATIONBASE)
20// Beam condition include(s):
22#endif // not XAOD_ANALYSIS or GENERATIONBASE
23
24#if !defined(XAOD_ANALYSIS) && !defined(SIMULATIONBASE) && !defined(GENERATIONBASE)
25// Luminosity include(s):
27#endif // not XAOD_ANALYSIS or SIMULATIONBASE or GENERATIONBASE
28
29// xAOD include(s):
31
32namespace xAODMaker {
33
43 public virtual IEventInfoCnvTool {
44
45 public:
47 EventInfoCnvTool( const std::string& type, const std::string& name,
48 const IInterface* parent );
49
51 virtual StatusCode initialize() override;
52
54 virtual StatusCode convert( const EventInfo* aod,
55 xAOD::EventInfo* xaod,
56 bool pileUpInfo = false,
57 bool copyPileUpLinks = true,
58 const EventContext& ctx = Gaudi::Hive::currentContext()) const override;
59
60 private:
61#if !defined(XAOD_ANALYSIS) && !defined(GENERATIONBASE)
62 SG::ReadCondHandleKey<InDet::BeamSpotData> m_beamSpotKey { this, "BeamSpotKey", "BeamSpotData", "SG key for beam spot" };
63 Gaudi::Property<bool> m_disableBeamSpot{ this, "DisableBeamSpot", false, "disable beamspot" };
64
67#endif // not XAOD_ANALYSIS or GENERATIONBASE
68
69#if !defined(XAOD_ANALYSIS) && !defined(SIMULATIONBASE) && !defined(GENERATIONBASE)
71 { this, "LumiDataKey", "", "SG key for luminosity data" };
72#endif // not XAOD_ANALYSIS or SIMULATIONBASE or GENERATIONBASE
73
74 }; // class EventInfoCnvTool
75
76} // namespace xAODMaker
77
78#endif // XAODEVENTINFOCNV_EVENTINFOCNVTOOL_H
Hold luminosity data produced by LuminosityCondAlg.
AthAlgTool(const std::string &type, const std::string &name, const IInterface *parent)
Constructor with parameters:
SG::ReadCondHandleKey< LuminosityCondData > m_lumiDataKey
Gaudi::Property< bool > m_disableBeamSpot
EventInfoCnvTool(const std::string &type, const std::string &name, const IInterface *parent)
Regular AlgTool constructor.
virtual StatusCode initialize() override
Function initialising the tool.
virtual StatusCode convert(const EventInfo *aod, xAOD::EventInfo *xaod, bool pileUpInfo=false, bool copyPileUpLinks=true, const EventContext &ctx=Gaudi::Hive::currentContext()) const override
Function that fills an existing xAOD::EventInfo object with data.
bool m_beamSpotInformationAvailable
Internal flag for the availability of the beam spot information.
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
Interface for the tool creating xAOD::EventInfo from an AOD.
EventInfo_v1 EventInfo
Definition of the latest event info version.