The Gaudi Framework  v41r0 (bdbe7744)
Loading...
Searching...
No Matches
TagCollectionStream.h
Go to the documentation of this file.
1/***********************************************************************************\
2* (c) Copyright 1998-2025 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#pragma once
12
13// Required for inheritance
14#include "OutputStream.h"
15#include <GaudiKernel/NTuple.h>
16
17// forward declarations
18class GenericAddress;
19
71protected:
72 Gaudi::Property<std::string> m_addrLeaf{ this, "AddressLeaf", "/Event",
73 "name of the address leaf in the transient event store" };
74 Gaudi::Property<std::string> m_addrColName{ this, "AddressColumn", "Address",
75 "name of the address column of the tag collection" };
76 Gaudi::Property<std::string> m_collSvcName{ this, "TagCollectionSvc", "NTupleSvc", "name of the collection service" };
77 Gaudi::Property<bool> m_objectsFirst{ this, "ObjectsFirst", true,
78 "flag to indicate that the objects should be written first" };
79 Gaudi::Property<std::string> m_tagName{ this, "Collection", "", "name of the tag collection in the transient store" };
80
84 std::string m_topLeafName;
86 bool m_isTopLeaf = false;
90 std::unique_ptr<GenericAddress> m_addr;
94 StatusCode writeObjects() override;
96 virtual StatusCode connectAddress();
103
104public:
106 TagCollectionStream( const std::string& name, ISvcLocator* pSvcLocator );
108 StatusCode initialize() override;
110 StatusCode finalize() override;
111};
const std::string & name() const override
The identifying name of the algorithm object.
Implementation of property with value of concrete type.
Definition Property.h:35
Generic Transient Address.
NTuple interface class definition.
Definition INTuple.h:32
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
Definition ISvcLocator.h:42
Class acting as a smart pointer holding a N tuple _Item.
Definition NTuple.h:251
A small to stream Data I/O.
Small smart pointer class with automatic reference counting for IInterface.
Definition SmartIF.h:28
This class is used for returning status codes from appropriate routines.
Definition StatusCode.h:64
StatusCode finalize() override
Terminate TagCollectionStream.
StatusCode writeTuple()
Write tuple data.
StatusCode writeObjects() override
OutputStream override: Select the different objects and write them to file.
StatusCode writeData()
Write data objects.
Gaudi::Property< std::string > m_addrColName
StatusCode writeRecord()
Write full event record.
Gaudi::Property< std::string > m_addrLeaf
virtual StatusCode connectAddress()
Connect address column, if not already connected.
std::unique_ptr< GenericAddress > m_addr
Address buffer.
SmartIF< INTupleSvc > m_collectionSvc
Keep reference to the tuple service.
Gaudi::Property< std::string > m_tagName
INTupleItem * m_addrColumn
NTuple column to hold the opaque address of the address leaf.
TagCollectionStream(const std::string &name, ISvcLocator *pSvcLocator)
Standard algorithm Constructor.
std::string m_topLeafName
Name of the top leaf (performance cache).
NTuple::Item< IOpaqueAddress * > m_item
Address item buffer.
Gaudi::Property< bool > m_objectsFirst
Gaudi::Property< std::string > m_collSvcName
StatusCode initialize() override
Initialize TagCollectionStream.
bool m_isTopLeaf
Short cut flag to indicate if the address leaf is the top leaf (performace cache).