152 for (
const CaloCell* cell : cellCont)
154 double theCellE=cell->energy();
155 if (
m_doEt) theCellE *= cell->sinTh();
178 if (CaloSampling::PreSamplerB == inum) {
180 (*m_Eh_PresB)[0] += theCellE;
182 else if (CaloSampling::PreSamplerE == inum) {
184 (*m_Eh_PresE)[0] += theCellE;
186 else if (CaloSampling::EMB1 == inum || CaloSampling::EMB2 == inum
187 || CaloSampling::EMB3 == inum) {
189 if (CaloSampling::EMB1 == inum) (*m_Eh_EMB)[0] += theCellE;
190 if (CaloSampling::EMB2 == inum) (*m_Eh_EMB)[1] += theCellE;
191 if (CaloSampling::EMB3 == inum) (*m_Eh_EMB)[2] += theCellE;
193 else if (CaloSampling::EME1 == inum || CaloSampling::EME2 == inum
194 || CaloSampling::EME3 == inum) {
196 if (CaloSampling::EME1 == inum) (*m_Eh_EMEC)[0] += theCellE;
197 if (CaloSampling::EME2 == inum) (*m_Eh_EMEC)[1] += theCellE;
198 if (CaloSampling::EME3 == inum) (*m_Eh_EMEC)[2] += theCellE;
200 else if (CaloSampling::TileBar0 == inum ||
201 CaloSampling::TileBar1 == inum ||
202 CaloSampling::TileBar2 == inum ||
203 CaloSampling::TileExt0 == inum ||
204 CaloSampling::TileExt1 == inum ||
205 CaloSampling::TileExt2 == inum ) {
207 if (CaloSampling::TileBar0 == inum ||
208 CaloSampling::TileExt0 == inum )
209 (*m_Eh_Tile)[0] += theCellE;
210 if (CaloSampling::TileBar1 == inum ||
211 CaloSampling::TileExt1 == inum )
212 (*m_Eh_Tile)[1] += theCellE;
213 if (CaloSampling::TileBar2 == inum ||
214 CaloSampling::TileExt2 == inum )
215 (*m_Eh_Tile)[2] += theCellE;
217 else if (CaloSampling::TileGap1 == inum ||
218 CaloSampling::TileGap2 == inum ||
219 CaloSampling::TileGap3 == inum ) {
221 (*m_Eh_TileGap)[0] += theCellE;
222 if (CaloSampling::TileGap3 == inum ) {
224 (*m_Eh_Scint)[0] += theCellE;
227 else if (CaloSampling::HEC0 == inum ||
228 CaloSampling::HEC1 == inum ||
229 CaloSampling::HEC2 == inum ||
230 CaloSampling::HEC3 == inum ) {
232 if (CaloSampling::HEC0 == inum ) (*m_Eh_HEC)[0] += theCellE;
233 if (CaloSampling::HEC1 == inum ) (*m_Eh_HEC)[1] += theCellE;
234 if (CaloSampling::HEC2 == inum ) (*m_Eh_HEC)[2] += theCellE;
235 if (CaloSampling::HEC3 == inum ) (*m_Eh_HEC)[3] += theCellE;
237 else if (CaloSampling::FCAL0 == inum ||
238 CaloSampling::FCAL1 == inum ||
239 CaloSampling::FCAL2 == inum ) {
241 if (CaloSampling::FCAL0 == inum ) (*m_Eh_FCal)[0] += theCellE;
242 if (CaloSampling::FCAL1 == inum ) (*m_Eh_FCal)[1] += theCellE;
243 if (CaloSampling::FCAL2 == inum ) (*m_Eh_FCal)[2] += theCellE;
255 return StatusCode::SUCCESS;