/
githubmirror
/
cmssw
Обзор
Документация
Войти
/
githubmirror
/
cmssw
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
SimCalorimetry/CastorSim/src/CastorCoderFactory.cc
22 строки
860 B
Sunanda
Reaarange the files to remove .h files from SimCalorimetry/CastorSim/src
18 авг 2021, 22:24
18 авг 2021, 22:24
5dd73cf
Код
Авторство
О чём код?
#include "CalibFormats/CastorObjects/interface/CastorCoderDb.h" #include "CalibFormats/CastorObjects/interface/CastorNominalCoder.h" #include "SimCalorimetry/CastorSim/interface/CastorCoderFactory.h" #include <cassert> CastorCoderFactory::CastorCoderFactory(CoderType coderType) : theCoderType(coderType), theDbService(nullptr) {} std::unique_ptr<CastorCoder> CastorCoderFactory::coder(const DetId &id) const { CastorCoder *result = nullptr; if (theCoderType == DB) { assert(theDbService != nullptr); HcalGenericDetId hcalGenDetId(id); const CastorQIECoder *qieCoder = theDbService->getCastorCoder(hcalGenDetId); const CastorQIEShape *qieShape = theDbService->getCastorShape(); result = new CastorCoderDb(*qieCoder, *qieShape); } else { result = new CastorNominalCoder(); } return std::unique_ptr<CastorCoder>(result); }