ATLAS Offline Software
Loading...
Searching...
No Matches
LayerMaterialMapCnv.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
3*/
4
6// LayerMaterialMapCnv.cxx, (c) ATLAS Detector software
8
10#include "GaudiKernel/IToolSvc.h"
11
12//-----------------------------------------------------------------------------
13// Constructor
14//-----------------------------------------------------------------------------
17 m_msgSvc( msgSvc() )
18{
19}
20
21//-----------------------------------------------------------------------------
22// Initializer
23//-----------------------------------------------------------------------------
25{
27 MsgStream log (m_msgSvc, "ElementTableCnv");
28 if( sc.isFailure() ) {
29 log << MSG::FATAL << "Could not initialize cnv base" << endmsg;
30 return sc;
31 }
32 //-------------------------------------------------------------------------
33 // Set up the message stream
34 //-------------------------------------------------------------------------
35 log << MSG::INFO << "LayerMaterialMapCnv::initialize()" << endmsg;
36
37 return StatusCode::SUCCESS;
38}
39
40
43 const std::string& key)
44{
45 MsgStream log (m_msgSvc, "LayerMaterialMapCnv: " + key);
46 return m_TPConverter_tlp1.createPersistent( transCont, log );
47}
48
49
50//-----------------------------------------------------------------------------
51// Create transient collection
52//-----------------------------------------------------------------------------
55{
56 static const pool::Guid tlp1_guid( "3DA92DBD-DA78-43A2-BFDF-9E19E2BF1E8A" );
57
58 Trk::LayerMaterialMap *p_collection = nullptr;
59
60 MsgStream log (m_msgSvc, "LayerMaterialMapCnv: " + key);
61
62 if( compareClassGuid( tlp1_guid ) ) {
64 p_collection = m_TPConverter_tlp1.createTransient( log );
65 }
66 return p_collection;
67}
#define endmsg
static Double_t sc
Trk::LayerMaterialMap_tlp1 LayerMaterialMap_PERS
T_AthenaPoolCustomCnvWithKey< Trk::LayerMaterialMap, LayerMaterialMap_PERS > LayerMaterialMapCnvBase
virtual Trk::LayerMaterialMap * createTransientWithKey(const std::string &key) override
method to be implemented by the developer.
virtual StatusCode initialize() override
Gaudi Service Interface method implementations:
LayerMaterialMapCnv_tlp1 m_TPConverter_tlp1
LayerMaterialMapCnv(ISvcLocator *svcloc)
virtual LayerMaterialMap_PERS * createPersistentWithKey(Trk::LayerMaterialMap *transCont, const std::string &key) override
method to be implemented by the developer.
This class extends the DataVector<Trk::LayerMaterialProperties> by an elementTable;.