CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
EcalReadoutTools.cc
Go to the documentation of this file.
2 
3 EcalReadoutTools::EcalReadoutTools(const edm::Event&, const edm::EventSetup& iSetup, const ESGetTokens& esGetTokens) {
5  elecMap_ = &iSetup.getData(esGetTokens.ecalElectronicsMappingToken);
6 }
7 
9  return triggerTowerMap_->towerOf(xtalId);
10 }
11 
13  const EcalElectronicsId& EcalElecId = elecMap_->getElectronicsId(xtalId);
14  int iDCC = EcalElecId.dccId();
15  int iDccChan = EcalElecId.towerId();
16  const bool ignoreSingle = true;
17  const std::vector<EcalScDetId> id = elecMap_->getEcalScDetId(iDCC, iDccChan, ignoreSingle);
18  return !id.empty() ? id[0] : EcalScDetId();
19 }
EcalReadoutTools(const edm::Event &, const edm::EventSetup &, const ESGetTokens &)
Ecal readout channel identification [32:20] Unused (so far) [19:13] DCC id [12:6] tower [5:3] strip [...
EcalTrigTowerDetId readOutUnitOf(const EBDetId &xtalId) const
int towerId() const
get the tower id
edm::ESGetToken< EcalElectronicsMapping, EcalMappingRcd > const ecalElectronicsMappingToken
EcalTrigTowerDetId towerOf(const DetId &id) const
Get the tower id for this det id (or null if not known)
bool getData(T &iHolder) const
Definition: EventSetup.h:128
EcalElectronicsId getElectronicsId(const DetId &id) const
Get the electronics id for this det id.
const EcalTrigTowerConstituentsMap * triggerTowerMap_
const EcalElectronicsMapping * elecMap_
int dccId() const
get the DCC (Ecal Local DCC value not global one) id
std::vector< EcalScDetId > getEcalScDetId(int DCCid, int DCC_Channel, bool ignoreSingleCrystal=true) const
edm::ESGetToken< EcalTrigTowerConstituentsMap, IdealGeometryRecord > const ecalTrigTowerConstituentsMapToken