2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
5 /** @file DataLinkCnv_p2.icc
6 * @brief This file contains the implementation for the DataLinkCnv_p2 template methods.
7 * @author Marcin.Nowak@cern.ch
13 template <typename DLINK_TYPE>
15 void DataLinkCnv_p2<DLINK_TYPE>::transToPers (const DLink_t& trans,
17 MsgStream& /*log*/) const
19 pers.m_SGKeyHash = trans.key();
22 template <typename DLINK_TYPE>
25 DataLinkCnv_p2<DLINK_TYPE>
26 ::transToPers(const DLink_t* trans, PersDLink_t* pers, MsgStream& log) const
28 this->transToPers(*trans, *pers, log);
33 template <typename DLINK_TYPE >
35 void DataLinkCnv_p2< DLINK_TYPE >::persToTrans (const PersDLink_t& pers,
37 MsgStream& /*log*/) const
39 if( pers.m_SGKeyHash ) {
40 trans.toIdentifiedObject( pers.m_SGKeyHash );
41 if( !trans.toTransient() ) {
42 throw std::runtime_error("DataLinkCnv_p2::persToTrans: failed to convert DataLink.");
48 template <typename DLINK_TYPE >
51 DataLinkCnv_p2< DLINK_TYPE >
52 ::persToTrans(const PersDLink_t* pers, DLink_t* trans, MsgStream& log) const
54 this->persToTrans(*pers, *trans, log);