CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Classes | Public Member Functions | Private Attributes
EcalReadoutTools Class Reference

#include <EcalReadoutTools.h>

Classes

struct  ESGetTokens
 

Public Member Functions

 EcalReadoutTools (const edm::Event &, const edm::EventSetup &, const ESGetTokens &)
 
 EcalReadoutTools (const EcalReadoutTools &)=delete
 
EcalReadoutToolsoperator= (const EcalReadoutTools &)=delete
 
EcalTrigTowerDetId readOutUnitOf (const EBDetId &xtalId) const
 
EcalScDetId readOutUnitOf (const EEDetId &xtalId) const
 

Private Attributes

const EcalElectronicsMappingelecMap_
 
const
EcalTrigTowerConstituentsMap
triggerTowerMap_
 

Detailed Description

Definition at line 12 of file EcalReadoutTools.h.

Constructor & Destructor Documentation

EcalReadoutTools::EcalReadoutTools ( const edm::Event ,
const edm::EventSetup iSetup,
const ESGetTokens esGetTokens 
)

Definition at line 3 of file EcalReadoutTools.cc.

References EcalReadoutTools::ESGetTokens::ecalElectronicsMappingToken, EcalReadoutTools::ESGetTokens::ecalTrigTowerConstituentsMapToken, elecMap_, edm::EventSetup::getData(), and triggerTowerMap_.

3  {
4  triggerTowerMap_ = &iSetup.getData(esGetTokens.ecalTrigTowerConstituentsMapToken);
5  elecMap_ = &iSetup.getData(esGetTokens.ecalElectronicsMappingToken);
6 }
bool getData(T &iHolder) const
Definition: EventSetup.h:128
const EcalTrigTowerConstituentsMap * triggerTowerMap_
const EcalElectronicsMapping * elecMap_
EcalReadoutTools::EcalReadoutTools ( const EcalReadoutTools )
delete

Member Function Documentation

EcalReadoutTools& EcalReadoutTools::operator= ( const EcalReadoutTools )
delete
EcalTrigTowerDetId EcalReadoutTools::readOutUnitOf ( const EBDetId xtalId) const

Definition at line 8 of file EcalReadoutTools.cc.

References EcalTrigTowerConstituentsMap::towerOf(), and triggerTowerMap_.

Referenced by HLTRechitsToDigis::produce().

8  {
9  return triggerTowerMap_->towerOf(xtalId);
10 }
EcalTrigTowerDetId towerOf(const DetId &id) const
Get the tower id for this det id (or null if not known)
const EcalTrigTowerConstituentsMap * triggerTowerMap_
EcalScDetId EcalReadoutTools::readOutUnitOf ( const EEDetId xtalId) const

Definition at line 12 of file EcalReadoutTools.cc.

References EcalElectronicsId::dccId(), elecMap_, EcalElectronicsMapping::getEcalScDetId(), EcalElectronicsMapping::getElectronicsId(), and EcalElectronicsId::towerId().

12  {
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 }
Ecal readout channel identification [32:20] Unused (so far) [19:13] DCC id [12:6] tower [5:3] strip [...
int towerId() const
get the tower id
EcalElectronicsId getElectronicsId(const DetId &id) const
Get the electronics id for this det id.
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

Member Data Documentation

const EcalElectronicsMapping* EcalReadoutTools::elecMap_
private

Definition at line 15 of file EcalReadoutTools.h.

Referenced by EcalReadoutTools(), and readOutUnitOf().

const EcalTrigTowerConstituentsMap* EcalReadoutTools::triggerTowerMap_
private

Definition at line 14 of file EcalReadoutTools.h.

Referenced by EcalReadoutTools(), and readOutUnitOf().