CMS 3D CMS Logo

TOBDetId Class Reference

#include <DataFormats/SiStripDetId/interface/TOBDetId.h>

Inheritance diagram for TOBDetId:

SiStripDetId DetId

List of all members.

Public Member Functions

bool isDoubleSide () const
 Returns true if the module is a double side = rphi + stereo.
bool isRPhi ()
 Returns true if the module is rphi.
bool isStereo ()
 Returns true if the module is stereo.
bool isZMinusSide () const
 Returns true if the module is in TOB- (z<0 side).
bool isZPlusSide () const
 Returns true if the module is in TOB+ (z>0 side).
unsigned int layer () const
 layer id
unsigned int layerNumber () const
 Returns the layer number.
unsigned int module () const
 detector id
unsigned int moduleNumber () const
 Returns the module number.
std::vector< unsigned introd () const
 rod id
unsigned int rodNumber () const
 Returns the rod number.
 TOBDetId (uint32_t layer, uint32_t rod_fw_bw, uint32_t rod, uint32_t module, uint32_t ster)
 TOBDetId (const DetId &id)
 Construct from generic DetId.
 TOBDetId (uint32_t rawid)
 Constructor from a raw value.
 TOBDetId ()
 Constructor of a null id.

Static Private Attributes

static const unsigned int layerMask_ = 0x7
 two bits would be enough, but we could use the number "0" as a wildcard
static const unsigned int layerStartBit_ = 14
 two bits would be enough, but we could use the number "0" as a wildcard
static const unsigned int moduleMask_ = 0x7
static const unsigned int moduleStartBit_ = 2
static const unsigned int rod_fw_bwMask_ = 0x3
static const unsigned int rod_fw_bwStartBit_ = 12
static const unsigned int rodMask_ = 0x7F
static const unsigned int rodStartBit_ = 5
static const unsigned int sterMask_ = 0x3
static const unsigned int sterStartBit_ = 0


Detailed Description

Definition at line 16 of file TOBDetId.h.


Constructor & Destructor Documentation

TOBDetId::TOBDetId (  ) 

Constructor of a null id.

Definition at line 3 of file TOBDetId.cc.

00003                    : SiStripDetId() {
00004 }

TOBDetId::TOBDetId ( uint32_t  rawid  ) 

Constructor from a raw value.

Definition at line 5 of file TOBDetId.cc.

00005                                  : SiStripDetId(rawid) {
00006 }

TOBDetId::TOBDetId ( const DetId id  ) 

Construct from generic DetId.

Definition at line 7 of file TOBDetId.cc.

00007                                   : SiStripDetId(id.rawId()) {
00008 }

TOBDetId::TOBDetId ( uint32_t  layer,
uint32_t  rod_fw_bw,
uint32_t  rod,
uint32_t  module,
uint32_t  ster 
) [inline]

Definition at line 25 of file TOBDetId.h.

References DetId::id_, layerMask_, layerStartBit_, moduleMask_, moduleStartBit_, rod_fw_bwMask_, rod_fw_bwStartBit_, rodMask_, rodStartBit_, sterMask_, and sterStartBit_.


Member Function Documentation

bool TOBDetId::isDoubleSide (  )  const

Returns true if the module is a double side = rphi + stereo.

Definition at line 10 of file TOBDetId.cc.

References layer().

Referenced by isRPhi(), and isStereo().

00010                                   {
00011   // Double Side: only layers 1 and 2
00012   if( this->glued() == 0 && ( this->layer() == 1 || this->layer() == 2 ) ) {
00013     return true;
00014   } else {
00015     return false;
00016   }
00017 }

bool TOBDetId::isRPhi (  )  [inline]

Returns true if the module is rphi.

Definition at line 83 of file TOBDetId.h.

References isDoubleSide(), and SiStripDetId::stereo().

Referenced by SiStripQualityConfigurableFakeESSource::isTOBDetector().

00084   { return (stereo() == 0 && !isDoubleSide());}

bool TOBDetId::isStereo (  )  [inline]

Returns true if the module is stereo.

Definition at line 87 of file TOBDetId.h.

References isDoubleSide(), and SiStripDetId::stereo().

Referenced by SiStripQualityConfigurableFakeESSource::isTOBDetector().

00088   { return (stereo() != 0 && !isDoubleSide());}

bool TOBDetId::isZMinusSide (  )  const [inline]

Returns true if the module is in TOB- (z<0 side).

Definition at line 67 of file TOBDetId.h.

References rod().

Referenced by isZPlusSide().

00068   { return (rod()[0] == 1);}

bool TOBDetId::isZPlusSide (  )  const [inline]

Returns true if the module is in TOB+ (z>0 side).

Definition at line 63 of file TOBDetId.h.

References isZMinusSide().

Referenced by SiStripQualityConfigurableFakeESSource::isTOBDetector().

00064   { return (!isZMinusSide());}

unsigned int TOBDetId::layer (  )  const [inline]

layer id

Definition at line 39 of file TOBDetId.h.

References DetId::id_, int, layerMask_, and layerStartBit_.

Referenced by SiStripCalibLorentzAngle::algoBeginJob(), SiStripDigiValid::analyze(), SiStripRecHitsValid::analyze(), SiStripLAProfileBooker::analyze(), SimHitTrackerAnalyzer::analyze(), SiStripTrackingRecHitsValid::analyze(), cms::ClusterAnalysis::book(), SiStripMonitorTrack::bookTrendMEs(), SiStripMonitorTrackEfficiency::bookTrendMEs(), SiStripMonitorTrackEfficiency::clusterInfos(), SiStripMonitorTrack::clusterInfos(), cms::ClusterAnalysis::clusterInfos(), RingMaker::determineExtensions(), RingMaker::dumpDetIds(), TrackerGeometryCompare::fillIdentifiers(), cms::ClusterAnalysis::fillPedNoiseFromDB(), RingMaker::fillTOBGeometryArray(), GlobalRecHitsProducer::fillTrk(), GlobalRecHitsAnalyzer::fillTrk(), GlobalDigisAnalyzer::fillTrk(), GlobalDigisProducer::fillTrk(), cms::ClusterMTCCFilter::filter(), SiTrackerGaussianSmearingRecHitConverter::gaussianSmearing(), SiStripCablingDQM::getActiveDetIds(), TrajectoryCleanerMerger::getLayer(), SiStripLAProfileBooker::getlayer(), SiStripMonitorCluster::getLayerLabel(), SiStripMonitorDigi::getLayerLabel(), SiStripGainCosmicCalculator::getNewObject(), SiStripSubStructure::getTOBDetectors(), isDoubleSide(), RoadSearchDetIdHelper::IsMatched(), RoadSearchDetIdHelper::IsSingleRPhi(), layerNumber(), TrajectoryManager::makeSinglePSimHit(), DetIdTOBSameLayerComparator::operator()(), RoadSearchDetIdHelper::Print(), SiStripFolderOrganizer::setLayerFolder(), and trackerHierarchy().

00039                             {
00040     return int((id_>>layerStartBit_) & layerMask_);
00041   }

unsigned int TOBDetId::layerNumber (  )  const [inline]

Returns the layer number.

Definition at line 71 of file TOBDetId.h.

References layer().

Referenced by SiStripQualityConfigurableFakeESSource::isTOBDetector().

00072   { return layer();}

unsigned int TOBDetId::module (  )  const [inline]

detector id

Definition at line 56 of file TOBDetId.h.

References DetId::id_, moduleMask_, and moduleStartBit_.

Referenced by SiStripDigiValid::analyze(), RingMaker::dumpDetIds(), TrackerGeometryCompare::fillIdentifiers(), RingMaker::fillTOBGeometryArray(), TrajectoryCleanerMerger::getLayer(), moduleNumber(), RoadSearchDetIdHelper::Print(), and trackerHierarchy().

00057     { return ((id_>>moduleStartBit_)& moduleMask_) ;}

unsigned int TOBDetId::moduleNumber (  )  const [inline]

Returns the module number.

Definition at line 79 of file TOBDetId.h.

References module().

00080   { return module();}

std::vector<unsigned int> TOBDetId::rod (  )  const [inline]

rod id

vector[0] = 1 -> bw rod (TOB-) vector[0] = 2 -> fw rod (TOB+) vector[1] -> rod

Definition at line 49 of file TOBDetId.h.

References DetId::id_, funct::num(), rod_fw_bwMask_, rod_fw_bwStartBit_, rodMask_, and rodStartBit_.

Referenced by SiStripCalibLorentzAngle::algoBeginJob(), SiStripDigiValid::analyze(), SiStripLAProfileBooker::analyze(), cms::ClusterAnalysis::book(), cms::ClusterAnalysis::clusterInfos(), RingMaker::determineExtensions(), RingMaker::dumpDetIds(), TrackerGeometryCompare::fillIdentifiers(), cms::ClusterAnalysis::fillPedNoiseFromDB(), RingMaker::fillTOBGeometryArray(), SiStripSubStructure::getTOBDetectors(), isZMinusSide(), RoadSearchDetIdHelper::Print(), rodNumber(), and trackerHierarchy().

00050     { std::vector<unsigned int> num;
00051     num.push_back(((id_>>rod_fw_bwStartBit_) & rod_fw_bwMask_));
00052     num.push_back(((id_>>rodStartBit_) & rodMask_));
00053     return num ;}

unsigned int TOBDetId::rodNumber (  )  const [inline]

Returns the rod number.

Definition at line 75 of file TOBDetId.h.

References rod().

Referenced by SiStripQualityConfigurableFakeESSource::isTOBDetector().

00076   { return rod()[1];}


Member Data Documentation

const unsigned int TOBDetId::layerMask_ = 0x7 [static, private]

two bits would be enough, but we could use the number "0" as a wildcard

Definition at line 99 of file TOBDetId.h.

Referenced by layer(), and TOBDetId().

const unsigned int TOBDetId::layerStartBit_ = 14 [static, private]

two bits would be enough, but we could use the number "0" as a wildcard

Definition at line 92 of file TOBDetId.h.

Referenced by layer(), and TOBDetId().

const unsigned int TOBDetId::moduleMask_ = 0x7 [static, private]

Definition at line 102 of file TOBDetId.h.

Referenced by module(), and TOBDetId().

const unsigned int TOBDetId::moduleStartBit_ = 2 [static, private]

Definition at line 95 of file TOBDetId.h.

Referenced by module(), and TOBDetId().

const unsigned int TOBDetId::rod_fw_bwMask_ = 0x3 [static, private]

Definition at line 100 of file TOBDetId.h.

Referenced by rod(), and TOBDetId().

const unsigned int TOBDetId::rod_fw_bwStartBit_ = 12 [static, private]

Definition at line 93 of file TOBDetId.h.

Referenced by rod(), and TOBDetId().

const unsigned int TOBDetId::rodMask_ = 0x7F [static, private]

Definition at line 101 of file TOBDetId.h.

Referenced by rod(), and TOBDetId().

const unsigned int TOBDetId::rodStartBit_ = 5 [static, private]

Definition at line 94 of file TOBDetId.h.

Referenced by rod(), and TOBDetId().

const unsigned int TOBDetId::sterMask_ = 0x3 [static, private]

Reimplemented from SiStripDetId.

Definition at line 103 of file TOBDetId.h.

Referenced by TOBDetId().

const unsigned int TOBDetId::sterStartBit_ = 0 [static, private]

Reimplemented from SiStripDetId.

Definition at line 96 of file TOBDetId.h.

Referenced by TOBDetId().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:33:40 2009 for CMSSW by  doxygen 1.5.4