TagCollectionStream.h
Go to the documentation of this file.
1 #ifndef GAUDISVC_PERSISTENCYSVC_TAGCOLLECTIONSTREAM_H
2 #define GAUDISVC_PERSISTENCYSVC_TAGCOLLECTIONSTREAM_H
3 
4 // Required for inheritance
5 #include "OutputStream.h"
6 #include "GaudiKernel/NTuple.h"
7 
8 // forward declarations
9 class GenericAddress;
10 
11 
63 protected:
64 
66  std::string m_addrLeaf = "/Event" ;
68  std::string m_addrColName = "Address" ;
70  std::string m_tagName;
72  std::string m_collSvcName = "NTupleSvc";
74  bool m_objectsFirst = true;
78  std::string m_topLeafName;
80  bool m_isTopLeaf = false;
84  std::unique_ptr<GenericAddress> m_addr;
88  StatusCode writeObjects() override;
90  virtual StatusCode connectAddress();
97 
98 public:
100  TagCollectionStream(const std::string& name, ISvcLocator* pSvcLocator);
102  ~TagCollectionStream() override = default;
104  StatusCode initialize() override;
106  StatusCode finalize() override;
107 };
108 
109 #endif // GAUDISVC_PERSISTENCYSVC_TAGCOLLECTIONSTREAM_H
std::string m_addrColName
Property: Name of the address column of the tag collection.
std::string m_tagName
Property: Name of the tag collection in the transient store.
virtual StatusCode connectAddress()
Connect address column, if not already connected.
TagCollectionStream(const std::string &name, ISvcLocator *pSvcLocator)
Standard algorithm Constructor.
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
Definition: ISvcLocator.h:25
StatusCode initialize() override
Initialize TagCollectionStream.
std::unique_ptr< GenericAddress > m_addr
Address buffer.
Specialized output stream class for event tag collections, where the basic Event entry point should b...
StatusCode writeData()
Write data objects.
INTupleItem * m_addrColumn
NTuple column to hold the opaque address of the address leaf.
Generic Transient Address.
StatusCode writeTuple()
Write tuple data.
bool m_objectsFirst
Property: Flag to indicate that the objects should be written first.
A small to stream Data I/O.
Definition: OutputStream.h:29
const std::string & name() const override
The identifying name of the algorithm object.
Definition: Algorithm.cpp:792
std::string m_addrLeaf
Property: Name of the address leaf in the transient event store.
StatusCode writeRecord()
Write full event record.
NTuple interface class definition.
Definition: INTuple.h:26
StatusCode finalize() override
Terminate TagCollectionStream.
This class is used for returning status codes from appropriate routines.
Definition: StatusCode.h:26
std::string m_collSvcName
Property: Name of the collection service.
~TagCollectionStream() override=default
Standard Destructor.
INTupleSvc * m_collectionSvc
Keep reference to the tuple service.
NTuple::Item< IOpaqueAddress * > m_item
Address item buffer.
bool m_isTopLeaf
Short cut flag to indicate if the address leaf is the top leaf (performace cache) ...
std::string m_topLeafName
Name of the top leaf (performance cache)
StatusCode writeObjects() override
OutputStream override: Select the different objects and write them to file.