The Gaudi Framework  master (37c0b60a)
EvtCollectionStream.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 // EvtCollectionStream.h
13 // --------------------------------------------------------------------
14 //
15 // Package : GaudiSvc/PersistencySvc
16 //
17 // Author : Markus Frank
18 //
19 // ====================================================================
20 #ifndef GAUDISVC_PERSISTENCYSVC_EVTCOLLECTIONSTREAM_H
21 #define GAUDISVC_PERSISTENCYSVC_EVTCOLLECTIONSTREAM_H
22 
23 // STL include files
24 #include <memory>
25 #include <string>
26 #include <vector>
27 
28 // Required for inheritance
29 #include <GaudiKernel/Algorithm.h>
30 
36 protected:
37  Gaudi::Property<std::vector<std::string>> m_itemNames{ this, "ItemList", {}, "vector of item names" };
38  Gaudi::Property<std::string> m_storeName{ this, "EvtDataSvc", "TagCollectionSvc",
39  "name of the service managing the data store" };
40 
45 
46 protected:
48  void clearItems();
50  void addItem( const std::string& descriptor );
51 
52 public:
56  StatusCode initialize() override;
58  StatusCode finalize() override;
60  StatusCode execute() override;
61 };
62 
63 #endif // GAUDISVC_PERSISTENCYSVC_EVTCOLLECTIONSTREAM_H
std::string
STL class.
std::vector
STL class.
EvtCollectionStream::execute
StatusCode execute() override
Working entry point.
Definition: EvtCollectionStream.cpp:57
Algorithm
Alias for backward compatibility.
Definition: Algorithm.h:58
Algorithm.h
EvtCollectionStream::m_itemList
std::vector< std::unique_ptr< DataStoreItem > > m_itemList
Vector of items to be saved to this stream.
Definition: EvtCollectionStream.h:44
EvtCollectionStream::clearItems
void clearItems()
Clear item list.
Definition: EvtCollectionStream.cpp:69
EvtCollectionStream
A small to stream Data I/O.
Definition: EvtCollectionStream.h:35
EvtCollectionStream::initialize
StatusCode initialize() override
Initialize EvtCollectionStream.
Definition: EvtCollectionStream.cpp:34
StatusCode
Definition: StatusCode.h:65
EvtCollectionStream::finalize
StatusCode finalize() override
Terminate EvtCollectionStream.
Definition: EvtCollectionStream.cpp:50
EvtCollectionStream::m_storeName
Gaudi::Property< std::string > m_storeName
Definition: EvtCollectionStream.h:38
SmartIF< INTupleSvc >
EvtCollectionStream::m_pTupleSvc
SmartIF< INTupleSvc > m_pTupleSvc
Reference to Tuple service for event collection (may or may not be NTuple service)
Definition: EvtCollectionStream.h:42
Gaudi::Algorithm::Algorithm
Algorithm(std::string name, ISvcLocator *svcloc, std::string version=PACKAGE_VERSION)
Constructor.
Definition: Algorithm.h:101
EvtCollectionStream::addItem
void addItem(const std::string &descriptor)
Add item to output streamer list.
Definition: EvtCollectionStream.cpp:72
EvtCollectionStream::m_itemNames
Gaudi::Property< std::vector< std::string > > m_itemNames
Definition: EvtCollectionStream.h:37
Gaudi::Property
Implementation of property with value of concrete type.
Definition: Property.h:37