51 std::string log_node, log_file, logical_name;
55 for (
auto attrib : Parser(
m_output ) ) {
64 tmp += attrib.tag +
"='" + attrib.value +
"' ";
71 std::string::size_type idx = ( tag[0] == SEPARATOR ) ? tag.find( SEPARATOR, 1 ) : 0;
72 log_node = tag.substr( idx, tag.find( SEPARATOR, idx + 1 ) );
74 log_file = log_node +
" " +
m_output +
" SHARED='YES'";
78 if ( sc.isSuccess() ) {
83 logical_name = data_mgr->rootName();
84 logical_name += SEPARATOR;
85 logical_name += log_node;
89 if ( src_mgr->isConnected( logical_name ) )
return sc;
90 sc = src_mgr->connect( log_file );
91 if ( sc.isSuccess() )
return sc;
95 error() <<
"Failed to initialize TagCollection Stream." <<
endmsg;
112 <<
"[Tuple write error]" <<
endmsg;
122 <<
"[Object write error]" <<
endmsg;
150 std::string* par =
const_cast<std::string*
>(
m_addr->par() );
151 unsigned long* ipar = (
unsigned long*)
m_addr->ipar();
154 par[0] = pA->
par()[0];
155 par[1] = pA->
par()[1];
156 ipar[0] = pA->
ipar()[0];
157 ipar[1] = pA->
ipar()[1];
173 par[0] = redir->
par()[0];
175 ipar[1] = redir->
ipar()[1];
void toupper(std::string &s)
MsgStream & endmsg(MsgStream &s)
MsgStream Modifier: endmsg. Calls the output method of the MsgStream.
SmartDataPtr< NTuple::Tuple > NTuplePtr
#define DECLARE_COMPONENT(type)
MsgStream & error() const
shortcut for the method msgStream(MSG::ERROR)
SmartIF< IDataProviderSvc > & eventSvc() const
The standard event data service.
SmartIF< IService > service(std::string_view name, const bool createIf=true, const bool quiet=false) const
Return a pointer to the service identified by name (or "type/name").
Parse attribute strings allowing iteration over the various attributes.
Generic Transient Address.
IDataSourceMgr interface definition.
Opaque address interface definition.
virtual long svcType() const =0
Retrieve service type.
virtual const unsigned long * ipar() const =0
Access to generic link parameters.
virtual const CLID & clID() const =0
Retrieve class information from link.
virtual const std::string * par() const =0
Retrieve String parameters.
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
A small to stream Data I/O.
StatusCode finalize() override
Terminate OutputStream.
virtual StatusCode writeObjects()
Select the different objects and write them to file.
StatusCode initialize() override
Initialize OutputStream.
Gaudi::Property< std::string > m_output
static DataObject * find(SmartDataObjectPtr *ptr)
Static Object find method.
A small class used to access easily (and efficiently) data items residing in data stores.
This class is used for returning status codes from appropriate routines.
constexpr static const auto SUCCESS
constexpr static const auto FAILURE
Specialized output stream class for event tag collections, where the basic Event entry point should b...
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).