The Gaudi Framework  master (37c0b60a)
EvtCollectionWrite.h
Go to the documentation of this file.
1 /***********************************************************************************\
2 * (c) Copyright 1998-2024 CERN for the benefit of the LHCb and ATLAS collaborations *
3 * *
4 * This software is distributed under the terms of the Apache version 2 licence, *
5 * copied verbatim in the file "LICENSE". *
6 * *
7 * In applying this licence, CERN does not waive the privileges and immunities *
8 * granted to it by virtue of its status as an Intergovernmental Organization *
9 * or submit itself to any jurisdiction. *
10 \***********************************************************************************/
11 // ====================================================================
12 // EvtCollection.Write.h
13 // --------------------------------------------------------------------
14 //
15 // Package : GaudiTestSuite/EvtCollection
16 //
17 // Author : Markus Frank
18 //
19 // ====================================================================
20 #ifndef EVTCOLLECTION_WRITE_H
21 #define EVTCOLLECTION_WRITE_H
22 
23 // Framework include files
24 #include <GaudiKernel/Algorithm.h> // Required for inheritance
25 #include <GaudiKernel/NTuple.h>
27 
28 // Forward declarations
29 class INtupleSvc;
30 
31 namespace Gaudi {
32  namespace TestSuite {
33  class MyTrack;
34  }
35 } // namespace Gaudi
44 class EvtCollectionWrite : public Algorithm {
45 
46  Gaudi::Property<int> m_nMCcut{ this, "NumMcTracks", 50, "" };
47 
55  ServiceHandle<INTupleSvc> m_evtTupleSvc{ this, "NTupleSvc", "EvtTupleSvc" };
56 
57 public:
61  StatusCode initialize() override;
63  StatusCode finalize() override { return StatusCode::SUCCESS; }
65  StatusCode execute() override;
66 };
67 
68 #endif // EVTCOLLECTION_WRITE_H
EvtCollectionWrite::m_ntrkColl
NTuple::Item< int > m_ntrkColl
Definition: EvtCollectionWrite.h:48
EvtCollectionWrite::m_trackItem
NTuple::Item< Gaudi::TestSuite::MyTrack * > m_trackItem
Definition: EvtCollectionWrite.h:50
EvtCollectionWrite::finalize
StatusCode finalize() override
Finalize.
Definition: EvtCollectionWrite.h:63
ServiceHandle< INTupleSvc >
TestSuite
#define TestSuite
Definition: MakeAndConsume.cpp:658
Algorithm
Alias for backward compatibility.
Definition: Algorithm.h:58
EvtCollectionWrite::m_evtAddrColl
NTuple::Item< IOpaqueAddress * > m_evtAddrColl
Definition: EvtCollectionWrite.h:53
Algorithm.h
EvtCollectionWrite
User example objects: EvtCollectionWrite.
Definition: EvtCollectionWrite.h:44
ServiceHandle.h
EvtCollectionWrite::execute
StatusCode execute() override
Event callback.
Definition: EvtCollectionWrite.cpp:69
StatusCode
Definition: StatusCode.h:65
EvtCollectionWrite::m_evtTupleSvc
ServiceHandle< INTupleSvc > m_evtTupleSvc
Definition: EvtCollectionWrite.h:55
NTuple.h
Gaudi
This file provides a Grammar for the type Gaudi::Accumulators::Axis It allows to use that type from p...
Definition: __init__.py:1
EvtCollectionWrite::m_trkMom
NTuple::Array< float > m_trkMom
Definition: EvtCollectionWrite.h:51
EvtCollectionWrite::m_evtAddrCollEx
NTuple::Item< IOpaqueAddress * > m_evtAddrCollEx
Definition: EvtCollectionWrite.h:54
StatusCode::SUCCESS
constexpr static const auto SUCCESS
Definition: StatusCode.h:100
EvtCollectionWrite::m_eneColl
NTuple::Item< float > m_eneColl
Definition: EvtCollectionWrite.h:49
EvtCollectionWrite::initialize
StatusCode initialize() override
Initialize.
Definition: EvtCollectionWrite.cpp:37
Gaudi::Algorithm::Algorithm
Algorithm(std::string name, ISvcLocator *svcloc, std::string version=PACKAGE_VERSION)
Constructor.
Definition: Algorithm.h:101
NTuple::Array< float >
EvtCollectionWrite::m_trkMomFixed
NTuple::Array< float > m_trkMomFixed
Definition: EvtCollectionWrite.h:52
Gaudi::Property< int >
EvtCollectionWrite::m_nMCcut
Gaudi::Property< int > m_nMCcut
Definition: EvtCollectionWrite.h:46
NTuple::Item< int >