ATLAS Offline Software
CaloHelpersTest.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 /*
5  */
16 
17 
19  : m_parser (std::make_unique<IdDictParser>())
20 {
21  m_parser->register_external_entity("LArCalorimeter", "IdDictLArCalorimeter.xml");
22  IdDictMgr& idd = m_parser->parse("IdDictParser/ATLAS_IDS.xml");
23  m_em_idHelper.set_quiet (true);
26  std::abort();
27  }
28 
31  std::abort();
32  }
33 
37  std::abort();
38  }
39 
43  std::abort();
44  }
45 
49  std::abort();
50  }
51 
52  m_calo_idHelper = std::make_unique<CaloCell_ID> (&m_em_idHelper,
57  m_calo_idHelper->set_quiet (true);
58  if (m_calo_idHelper->initialize_from_dictionary(idd) != 0) {
59  std::abort();
60  }
61 }
62 
63 
65 = default;
66 
67 
69 {
70  return m_em_idHelper;
71 }
72 
73 
75 {
76  return m_hec_idHelper;
77 }
78 
79 
81 {
82  return m_fcal_idHelper;
83 }
84 
85 
87 {
88  return m_minifcal_idHelper;
89 }
90 
91 
93 {
94  return m_tile_idHelper;
95 }
96 
97 
99 {
100  return *m_calo_idHelper;
101 }
CaloHelpersTest::hecID
const LArHEC_ID & hecID() const
Definition: CaloHelpersTest.cxx:74
make_unique
std::unique_ptr< T > make_unique(Args &&... args)
Definition: SkimmingToolEXOT5.cxx:23
CaloHelpersTest::tileID
const TileID & tileID() const
Definition: CaloHelpersTest.cxx:92
CaloHelpersTest::m_calo_idHelper
std::unique_ptr< CaloCell_ID > m_calo_idHelper
Definition: CaloHelpersTest.h:57
LArHEC_ID
Helper class for LArHEC offline identifiers.
Definition: LArHEC_ID.h:85
CaloHelpersTest::minifcalID
const LArMiniFCAL_ID & minifcalID() const
Definition: CaloHelpersTest.cxx:86
CaloHelpersTest.h
Helper to initialize ID helpers for unit tests.
LArEM_ID::initialize_from_dictionary
virtual int initialize_from_dictionary(const IdDictMgr &dict_mgr)
initialization from the identifier dictionary
Definition: LArEM_ID.cxx:27
CaloHelpersTest::~CaloHelpersTest
~CaloHelpersTest()
CaloHelpersTest::m_parser
std::unique_ptr< IdDictParser > m_parser
Definition: CaloHelpersTest.h:51
LArHEC_ID::initialize_from_dictionary
virtual int initialize_from_dictionary(const IdDictMgr &dict_mgr)
initialization from the identifier dictionary
Definition: LArHEC_ID.cxx:27
AtlasDetectorID::set_quiet
void set_quiet(bool quiet)
Set flag for suppressing informational output.
Definition: AtlasDetectorID.cxx:753
IdDictMgr
Definition: IdDictDefs.h:32
IdDictParser.h
AtlasDetectorID::set_do_neighbours
virtual void set_do_neighbours(bool do_neighbours) override
Definition: AtlasDetectorID.cxx:743
TileID
Helper class for TileCal offline identifiers.
Definition: TileID.h:68
CaloHelpersTest::m_em_idHelper
LArEM_ID m_em_idHelper
Definition: CaloHelpersTest.h:52
CaloHelpersTest::CaloHelpersTest
CaloHelpersTest()
Definition: CaloHelpersTest.cxx:18
IdDictParser
Definition: IdDictParser.h:12
CaloCell_ID
Helper class for offline cell identifiers.
Definition: CaloCell_ID.h:34
CaloHelpersTest::m_tile_idHelper
TileID m_tile_idHelper
Definition: CaloHelpersTest.h:56
CaloHelpersTest::m_hec_idHelper
LArHEC_ID m_hec_idHelper
Definition: CaloHelpersTest.h:53
CaloHelpersTest::m_fcal_idHelper
LArFCAL_ID m_fcal_idHelper
Definition: CaloHelpersTest.h:54
CaloHelpersTest::m_minifcal_idHelper
LArMiniFCAL_ID m_minifcal_idHelper
Definition: CaloHelpersTest.h:55
CaloHelpersTest::fcalID
const LArFCAL_ID & fcalID() const
Definition: CaloHelpersTest.cxx:80
CaloHelpersTest::caloID
const CaloCell_ID & caloID() const
Definition: CaloHelpersTest.cxx:98
LArMiniFCAL_ID
Helper class for LArMiniFCAL offline identifiers.
Definition: LArMiniFCAL_ID.h:57
TileID::initialize_from_dictionary
virtual int initialize_from_dictionary(const IdDictMgr &dict_mgr)
initialization from the identifier dictionary
Definition: TileID.cxx:33
LArMiniFCAL_ID::initialize_from_dictionary
virtual int initialize_from_dictionary(const IdDictMgr &dict_mgr)
initialization from the identifier dictionary
Definition: LArMiniFCAL_ID.cxx:213
LArEM_ID
Helper class for LArEM offline identifiers.
Definition: LArEM_ID.h:118
LArFCAL_ID
Helper class for LArFCAL offline identifiers.
Definition: LArFCAL_ID.h:60
CaloHelpersTest::emID
const LArEM_ID & emID() const
Definition: CaloHelpersTest.cxx:68
LArFCAL_ID::initialize_from_dictionary
virtual int initialize_from_dictionary(const IdDictMgr &dict_mgr)
initialization from the identifier dictionary
Definition: LArFCAL_ID.cxx:32