![]() |
![]() |
00001 #ifndef Alignment_CommonAlignment_TOBNameSpace_H 00002 #define Alignment_CommonAlignment_TOBNameSpace_H 00003 00015 #include "CondFormats/Alignment/interface/Definitions.h" 00016 #include "DataFormats/TrackerCommon/interface/TrackerTopology.h" 00017 #include "Geometry/Records/interface/IdealGeometryRecord.h" 00018 00019 namespace align 00020 { 00021 namespace tob 00022 { 00024 inline unsigned int moduleNumber(align::ID, const TrackerTopology*); 00025 00027 inline unsigned int rodNumber(align::ID, const TrackerTopology*); 00028 00030 inline unsigned int layerNumber(align::ID, const TrackerTopology*); 00031 00033 inline unsigned int halfBarrelNumber(align::ID, const TrackerTopology*); 00034 } 00035 } 00036 00037 unsigned int align::tob::moduleNumber(align::ID id, const TrackerTopology* tTopo) 00038 { 00039 return tTopo->tobModule(id); 00040 } 00041 00042 unsigned int align::tob::rodNumber(align::ID id, const TrackerTopology* tTopo) 00043 { 00044 return tTopo->tobRodInfo(id)[1]; 00045 } 00046 00047 unsigned int align::tob::layerNumber(align::ID id, const TrackerTopology* tTopo) 00048 { 00049 return tTopo->tobLayer(id); 00050 } 00051 00052 unsigned int align::tob::halfBarrelNumber(align::ID id, const TrackerTopology* tTopo) 00053 { 00054 return tTopo->tobRodInfo(id)[0]; 00055 } 00056 00057 #endif