ATLAS Offline Software
Loading...
Searching...
No Matches
CaloTester.h
Go to the documentation of this file.
1// This file's extension implies that it's C, but it's really -*- C++ -*-.
2/*
3 Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration
4*/
5/*
6 */
13
14
15#ifndef CALOEVENT_CALOTESTER_H
16#define CALOEVENT_CALOTESTER_H
17
18
19#include "CaloEvent/CaloCell.h"
22#include "CaloDetDescr/CaloDetDescrElement.h"
25#include <memory>
26#include <vector>
27
28
41{
42public:
50 CaloTester();
51
52
57 StatusCode record_mgr();
58
59
66 const CaloDetDescriptor* find_dd (int hashid);
67
68
75 const CaloDetDescriptor* find_dd (const Identifier& cell_id);
76
77
82 std::unique_ptr<CaloCell> make_cell (int hashid);
83
84
89 std::vector<CaloCell*> get_cells();
90
91
96 std::vector<const CaloCell*> get_const_cells();
97
98
104 std::unique_ptr<CaloCellContainer> make_ccc();
105
106
109
110
112 const CaloHelpersTest& helpers() const { return m_helpers; }
113
114
116 const LArEM_ID& emID() const { return m_helpers.emID(); }
117
118
120 const LArHEC_ID& hecID() const { return m_helpers.hecID(); }
121
122
124 const LArFCAL_ID& fcalID() const { return m_helpers.fcalID(); }
125
126
128 const LArMiniFCAL_ID& minifcalID() const { return m_helpers.minifcalID(); }
129
130
132 const TileID& tileID() const { return m_helpers.tileID(); }
133
134
136 const CaloCell_ID& caloID() const { return m_helpers.caloID(); }
137
138
139private:
143 void make_cells();
144
147
150 std::vector<std::unique_ptr<CaloDetDescrElement> > m_tileddes;
151
153 std::vector<std::unique_ptr<CaloCell> > m_cells;
154
157
160 std::unique_ptr<CaloDetDescrManager> m_mgr_up;
161};
162
163
164#endif // not CALOEVENT_CALOTESTER_H
Definition of CaloDetDescrManager.
Definition of CaloDetDescriptor.
Helper to initialize ID helpers for unit tests.
Helper class for offline cell identifiers.
Definition CaloCell_ID.h:34
This class provides the client interface for accessing the detector description information common to...
This is a base class for LAr and Tile Descriptors The primary goal is to speed up loops over all the ...
Helper to initialize ID helpers for unit tests.
void make_cells()
Create all calo cells and save in internal list.
const LArHEC_ID & hecID() const
Return the LArHEC ID helper.
Definition CaloTester.h:120
CaloHelpersTest m_helpers
The ID helpers.
Definition CaloTester.h:146
std::unique_ptr< CaloCell > make_cell(int hashid)
Create a calorimeter cell.
std::vector< std::unique_ptr< CaloCell > > m_cells
The cells made by make_cells().
Definition CaloTester.h:153
std::unique_ptr< CaloDetDescrManager > m_mgr_up
Owning pointer to the manager object.
Definition CaloTester.h:160
std::unique_ptr< CaloCellContainer > make_ccc()
Return a CaloCellContainer for all cells.
std::vector< std::unique_ptr< CaloDetDescrElement > > m_tileddes
All Tile detdescr elements.
Definition CaloTester.h:150
CaloDetDescrManager * m_mgr
The manager object.
Definition CaloTester.h:156
const CaloCell_ID & caloID() const
Return the Calorimeter ID helper.
Definition CaloTester.h:136
const LArFCAL_ID & fcalID() const
Return the LArFCAL ID helper.
Definition CaloTester.h:124
std::vector< CaloCell * > get_cells()
Return a vector of all cells.
const LArEM_ID & emID() const
Return the LArEM ID helper.
Definition CaloTester.h:116
std::vector< const CaloCell * > get_const_cells()
Return a vector of all cells as const pointers.
const CaloHelpersTest & helpers() const
Return the ID helpers.
Definition CaloTester.h:112
StatusCode record_mgr()
Record the CaloDetDescrManager in the detector store.
const LArMiniFCAL_ID & minifcalID() const
Return the LArMiniFCAL ID helper.
Definition CaloTester.h:128
CaloDetDescrManager & mgr()
Return the CaloDetDescrManager.
Definition CaloTester.h:108
const TileID & tileID() const
Return the Tile ID helper.
Definition CaloTester.h:132
const CaloDetDescriptor * find_dd(int hashid)
Return a region descriptor corresponding to a given cell.
CaloTester()
Constructor.
Helper class for LArEM offline identifiers.
Definition LArEM_ID.h:111
Helper class for LArFCAL offline identifiers.
Definition LArFCAL_ID.h:49
Helper class for LArHEC offline identifiers.
Definition LArHEC_ID.h:76
Helper class for LArMiniFCAL offline identifiers.
Helper class for TileCal offline identifiers.
Definition TileID.h:67