#include <EcalHodoscopeNumberingScheme.h>
Public Member Functions | |
EcalHodoscopeNumberingScheme () | |
virtual uint32_t | getUnitID (const EcalBaseNumber &baseNumber) const |
~EcalHodoscopeNumberingScheme () |
Definition at line 10 of file EcalHodoscopeNumberingScheme.h.
EcalHodoscopeNumberingScheme::EcalHodoscopeNumberingScheme | ( | ) |
Definition at line 11 of file EcalHodoscopeNumberingScheme.cc.
: EcalNumberingScheme() { edm::LogInfo("EcalTBGeom") << "Creating EcalHodoscopeNumberingScheme"; }
EcalHodoscopeNumberingScheme::~EcalHodoscopeNumberingScheme | ( | ) |
Definition at line 17 of file EcalHodoscopeNumberingScheme.cc.
{ edm::LogInfo("EcalTBGeom") << "Deleting EcalHodoscopeNumberingScheme"; }
uint32_t EcalHodoscopeNumberingScheme::getUnitID | ( | const EcalBaseNumber & | baseNumber | ) | const [virtual] |
Implements EcalNumberingScheme.
Definition at line 22 of file EcalHodoscopeNumberingScheme.cc.
References EcalBaseNumber::getCopyNumber(), EcalBaseNumber::getLevelName(), EcalBaseNumber::getLevels(), testEve_cfg::level, LogDebug, and DetId::rawId().
Referenced by EcalTBHodoscopeGeometryLoaderFromDDD::getDetIdForDDDNode().
{ int level = baseNumber.getLevels(); uint32_t intIndex = 0; if (level > 0) { // depth index - plans and fibers if(baseNumber.getLevelName(0) == "FIBR") { uint32_t iFibr; if (baseNumber.getCopyNumber(0) > 32) iFibr = 2 * (baseNumber.getCopyNumber(0)-33); else iFibr = 2*baseNumber.getCopyNumber(0) - 1; const uint32_t iPlane = baseNumber.getCopyNumber(1)-1; LogDebug("EcalTBGeom") << "Fibr/plane " << iFibr << " " << iPlane; intIndex = HodoscopeDetId( iPlane, iFibr ).rawId() ; LogDebug("EcalTBGeom") << "Index for fiber volume " << baseNumber.getLevelName(0) << " in plane " << baseNumber.getLevelName(1) << " = " << intIndex; } } return intIndex; }