ATLAS Offline Software
CaloTopoSplitterClusterCell.h
Go to the documentation of this file.
1 // Yo emacs, this is -*- C++ -*-
2 
3 /*
4  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 //-----------------------------------------------------------------------
8 // File and Version Information:
9 //
10 // Description: ClusterCell Container for the topological cluster splitter
11 //
12 // Environment:
13 // Software developed for the ATLAS Detector at the CERN LHC
14 //
15 // Author List:
16 // Sven Menke
17 //
18 //-----------------------------------------------------------------------
19 
20 #ifndef CALOTOPOSPLITTERCLUSTERCELL_H
21 #define CALOTOPOSPLITTERCLUSTERCELL_H
22 
25 
27 
29 {
30 
31 private:
32 
33  // Friends
34 
35  // Data members
36 
42  bool m_shared;
43  float m_weight;
45 
46 public:
47 
48  // Constructors
49 
51  const CaloCell_ID::SUBCALO subDet,
53  const size_t & iCell, //This is actually obsolete, can be obtained from iterator
54  const float & signedRatio,
55  const xAOD::CaloCluster *pClus,
56  const size_t caloClusterIndex,
57  const bool isSecondary=false)
58  : CaloTopoTmpClusterCellBase(idHash,subDet,iCell,signedRatio),
59  m_cluster(0),
60  m_parentCluster(pClus),
61  m_itrCell(itrCell),
62  m_parentClusterIndex(caloClusterIndex),
64  {
65  m_shared = false;
66  m_secondCluster = 0;
67  m_weight=1.;
68  }
69 
70  inline const xAOD::CaloCluster * getParentCluster() const
71  {
72  return m_parentCluster;
73  }
74 
76  {
77  return m_itrCell;
78  }
79 
80  inline size_t getParentClusterIndex() const
81  {
82  return m_parentClusterIndex;
83  }
84 
85  inline bool getShared() const
86  {
87  return m_shared;
88  }
89 
90  inline void
92  {
93  m_secondCluster = cluster;
94  }
95 
97  {
98  return m_secondCluster;
99  }
100 
101  inline void setShared()
102  {
103  m_shared = true;
104  }
105 
106  inline void setSharedWeight(const float &weight)
107  {
108  m_weight = weight;
109  }
110 
111  inline const float & getSharedWeight()
112  {
113  return m_weight;
114  }
115 
116  inline void setUnshared()
117  {
118  m_shared = false;
119  }
120 
122  {
123  return m_cluster;
124  }
125 
127  {
128  return m_cluster;
129  }
130 
132  {
133  m_cluster = cluster;
134  }
135 
136  inline bool getSecondary() const
137  {
138  return m_secondary;
139  }
140 
141 
142 
143 };
144 
145 #endif // CALOTOPOSPLITTERCLUSTERCELL_H
146 
CaloTopoTmpClusterCellBase
Definition: CaloTopoTmpClusterCellBase.h:28
CaloTopoSplitterClusterCell::getSecondary
bool getSecondary() const
Definition: CaloTopoSplitterClusterCell.h:136
CaloTopoSplitterClusterCell::getCaloTopoTmpHashCluster
CaloTopoSplitterHashCluster * getCaloTopoTmpHashCluster()
Definition: CaloTopoSplitterClusterCell.h:126
CaloTopoSplitterClusterCell::setCaloTopoTmpHashCluster
void setCaloTopoTmpHashCluster(CaloTopoSplitterHashCluster *cluster)
Definition: CaloTopoSplitterClusterCell.h:131
CaloTopoSplitterHashCluster
Definition: CaloTopoSplitterHashCluster.h:34
CaloTopoSplitterClusterCell::setSecondCaloTopoTmpHashCluster
void setSecondCaloTopoTmpHashCluster(CaloTopoSplitterHashCluster *cluster)
Definition: CaloTopoSplitterClusterCell.h:91
CaloTopoSplitterClusterCell::setUnshared
void setUnshared()
Definition: CaloTopoSplitterClusterCell.h:116
CaloTopoSplitterClusterCell::getParentClusterIndex
size_t getParentClusterIndex() const
Definition: CaloTopoSplitterClusterCell.h:80
dqt_zlumi_pandas.weight
int weight
Definition: dqt_zlumi_pandas.py:189
CaloTopoSplitterClusterCell::m_itrCell
xAOD::CaloCluster::cell_iterator m_itrCell
Definition: CaloTopoSplitterClusterCell.h:39
CaloTopoSplitterClusterCell
Definition: CaloTopoSplitterClusterCell.h:29
xAOD::CaloCluster_v1
Description of a calorimeter cluster.
Definition: CaloCluster_v1.h:59
CaloTopoSplitterClusterCell::m_parentCluster
const xAOD::CaloCluster * m_parentCluster
Definition: CaloTopoSplitterClusterCell.h:38
CaloTopoSplitterClusterCell::m_secondary
bool m_secondary
Definition: CaloTopoSplitterClusterCell.h:44
CaloTopoSplitterClusterCell::m_secondCluster
CaloTopoSplitterHashCluster * m_secondCluster
Definition: CaloTopoSplitterClusterCell.h:41
CaloTopoSplitterClusterCell::getShared
bool getShared() const
Definition: CaloTopoSplitterClusterCell.h:85
CaloCluster.h
CaloCell_Base_ID::SUBCALO
SUBCALO
enumeration of sub calorimeters
Definition: CaloCell_Base_ID.h:46
CaloTopoSplitterClusterCell::m_cluster
CaloTopoSplitterHashCluster * m_cluster
Definition: CaloTopoSplitterClusterCell.h:37
CaloTopoSplitterClusterCell::getSecondCaloTopoTmpHashCluster
CaloTopoSplitterHashCluster * getSecondCaloTopoTmpHashCluster()
Definition: CaloTopoSplitterClusterCell.h:96
CaloTopoSplitterClusterCell::setSharedWeight
void setSharedWeight(const float &weight)
Definition: CaloTopoSplitterClusterCell.h:106
CaloTopoSplitterClusterCell::CaloTopoSplitterClusterCell
CaloTopoSplitterClusterCell(const IdentifierHash &idHash, const CaloCell_ID::SUBCALO subDet, xAOD::CaloCluster::cell_iterator &itrCell, const size_t &iCell, const float &signedRatio, const xAOD::CaloCluster *pClus, const size_t caloClusterIndex, const bool isSecondary=false)
Definition: CaloTopoSplitterClusterCell.h:50
InDet::TrkOrigin::isSecondary
bool isSecondary(int origin)
from long living particle decays or gamma conversions or hadronic interactions and anything else with...
Definition: InDetTrackTruthOriginDefs.h:104
CaloTopoSplitterClusterCell::getSharedWeight
const float & getSharedWeight()
Definition: CaloTopoSplitterClusterCell.h:111
CaloTopoSplitterClusterCell::getCellIterator
const xAOD::CaloCluster::cell_iterator & getCellIterator() const
Definition: CaloTopoSplitterClusterCell.h:75
CaloTopoSplitterClusterCell::m_weight
float m_weight
Definition: CaloTopoSplitterClusterCell.h:43
CaloTopoSplitterClusterCell::getParentCluster
const xAOD::CaloCluster * getParentCluster() const
Definition: CaloTopoSplitterClusterCell.h:70
CaloTopoSplitterClusterCell::setShared
void setShared()
Definition: CaloTopoSplitterClusterCell.h:101
CaloTopoSplitterClusterCell::m_parentClusterIndex
size_t m_parentClusterIndex
Definition: CaloTopoSplitterClusterCell.h:40
CaloTopoSplitterClusterCell::m_shared
bool m_shared
Definition: CaloTopoSplitterClusterCell.h:42
IdentifierHash
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
Definition: IdentifierHash.h:25
CaloTopoSplitterClusterCell::getCaloTopoTmpHashCluster
const CaloTopoSplitterHashCluster * getCaloTopoTmpHashCluster() const
Definition: CaloTopoSplitterClusterCell.h:121
CaloTopoTmpClusterCellBase.h