CMS 3D CMS Logo

HGCalTowerMap.h
Go to the documentation of this file.
1 #ifndef DataFormats_L1TCalorimeter_HGCalTowerMap_h
2 #define DataFormats_L1TCalorimeter_HGCalTowerMap_h
3 
6 
7 #include <unordered_map>
8 
9 namespace l1t {
10 
11  class HGCalTowerMap;
14 
15  class HGCalTowerMap {
16 
17  public:
18 
20 
21  HGCalTowerMap(const std::vector<l1t::HGCalTowerCoord>& tower_ids, const int layer);
22 
23  int layer() const { return layer_; }
24 
26 
27  bool addEt(short bin_id, float etEm, float etHad);
28 
29  unsigned nTowers() const { return towerMap_.size(); }
30  const std::unordered_map<unsigned short, l1t::HGCalTower>& towers() const { return towerMap_; }
31 
32 
33  private:
34 
35  std::unordered_map<unsigned short, l1t::HGCalTower> towerMap_;
36  unsigned layer_;
37 
38  };
39 
40 }
41 
42 #endif
const std::unordered_map< unsigned short, l1t::HGCalTower > & towers() const
Definition: HGCalTowerMap.h:30
bool addEt(short bin_id, float etEm, float etHad)
delete x;
Definition: CaloConfig.h:22
BXVector< HGCalTowerMap > HGCalTowerMapBxCollection
Definition: HGCalTowerMap.h:12
const HGCalTowerMap & operator+=(const HGCalTowerMap &map)
int layer() const
Definition: HGCalTowerMap.h:23
std::unordered_map< unsigned short, l1t::HGCalTower > towerMap_
Definition: HGCalTowerMap.h:35
unsigned nTowers() const
Definition: HGCalTowerMap.h:29