CMS 3D CMS Logo

Typedefs | Functions | Variables

/data/doxygen/doxygen-1.7.3/gen/CMSSW_4_2_8/src/SimTracker/TrackHistory/src/TrackQuality.cc File Reference

#include <algorithm>
#include <vector>
#include "FWCore/ParameterSet/interface/ParameterSet.h"
#include "SimDataFormats/TrackingAnalysis/interface/TrackingParticleFwd.h"
#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h"
#include "DataFormats/DetId/interface/DetId.h"
#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h"
#include "DataFormats/SiPixelDetId/interface/PXBDetId.h"
#include "DataFormats/SiPixelDetId/interface/PXFDetId.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"
#include "DataFormats/SiStripDetId/interface/TIBDetId.h"
#include "DataFormats/SiStripDetId/interface/TIDDetId.h"
#include "DataFormats/SiStripDetId/interface/TOBDetId.h"
#include "DataFormats/SiStripDetId/interface/TECDetId.h"
#include "DataFormats/MuonDetId/interface/MuonSubdetId.h"
#include "DataFormats/MuonDetId/interface/DTLayerId.h"
#include "DataFormats/MuonDetId/interface/CSCDetId.h"
#include "DataFormats/MuonDetId/interface/RPCDetId.h"
#include "DataFormats/TrackingRecHit/interface/TrackingRecHit.h"
#include "DataFormats/TrackingRecHit/interface/TrackingRecHitFwd.h"
#include "DataFormats/TrackReco/interface/Track.h"
#include "DataFormats/TrackReco/interface/TrackFwd.h"
#include "SimTracker/TrackerHitAssociation/interface/TrackerHitAssociator.h"
#include "SimTracker/TrackHistory/interface/TrackQuality.h"

Go to the source code of this file.

Typedefs

typedef std::pair
< TrackQuality::Layer::SubDet,
short int > 
DetLayer

Functions

static DetLayer getDetLayer (DetId detId)

Variables

static const int statePriorities []

Typedef Documentation

typedef std::pair<TrackQuality::Layer::SubDet, short int> DetLayer

Definition at line 86 of file TrackQuality.cc.


Function Documentation

static DetLayer getDetLayer ( DetId  detId) [static]

Definition at line 101 of file TrackQuality.cc.

References MuonSubdetId::CSC, CSCDetId, DetId::det(), PXFDetId::disk(), MuonSubdetId::DT, DTLayerId, TrackQuality::Layer::Invalid, TIBDetId::layer(), TOBDetId::layer(), PXBDetId::layer(), DetId::Muon, TrackQuality::Layer::MuonCSC, TrackQuality::Layer::MuonDT, TrackQuality::Layer::MuonRPCBarrel, TrackQuality::Layer::MuonRPCEndcap, TrackQuality::Layer::PixelBarrel, PixelSubdetector::PixelBarrel, PixelSubdetector::PixelEndcap, TrackQuality::Layer::PixelForward, MuonSubdetId::RPC, RPCDetId, TrackQuality::Layer::StripTEC, TrackQuality::Layer::StripTIB, TrackQuality::Layer::StripTID, TrackQuality::Layer::StripTOB, DetId::subdetId(), StripSubdetector::TEC, StripSubdetector::TIB, StripSubdetector::TID, StripSubdetector::TOB, DetId::Tracker, TIDDetId::wheel(), and TECDetId::wheel().

Referenced by TrackQuality::evaluate().

{
    TrackQuality::Layer::SubDet det = TrackQuality::Layer::Invalid;
    short int layer = 0;

    switch (detId.det())
    {
    case DetId::Tracker:
        switch (detId.subdetId())
        {
        case PixelSubdetector::PixelBarrel:
            det = TrackQuality::Layer::PixelBarrel;
            layer = PXBDetId(detId).layer();
            break;

        case PixelSubdetector::PixelEndcap:
            det = TrackQuality::Layer::PixelForward;
            layer = PXFDetId(detId).disk();
            break;

        case StripSubdetector::TIB:
            det = TrackQuality::Layer::StripTIB;
            layer = TIBDetId(detId).layer();
            break;

        case StripSubdetector::TID:
            det = TrackQuality::Layer::StripTID;
            layer = TIDDetId(detId).wheel();
            break;

        case StripSubdetector::TOB:
            det = TrackQuality::Layer::StripTOB;
            layer = TOBDetId(detId).layer();
            break;

        case StripSubdetector::TEC:
            det = TrackQuality::Layer::StripTEC;
            layer = TECDetId(detId).wheel();
            break;

        default:
            /* should not get here */
            ;
        }
        break;

    case DetId::Muon:
        switch (detId.subdetId())
        {
        case MuonSubdetId::DT:
            det = TrackQuality::Layer::MuonDT;
            layer = DTLayerId(detId).layer();
            break;

        case MuonSubdetId::CSC:
            det = TrackQuality::Layer::MuonCSC;
            layer = CSCDetId(detId).layer();
            break;

        case MuonSubdetId::RPC:
            if (RPCDetId(detId).region())
                det = TrackQuality::Layer::MuonRPCEndcap;
            else
                det = TrackQuality::Layer::MuonRPCBarrel;
            layer = RPCDetId(detId).layer();
            break;

        default:
            /* should not get here */
            ;
        }
        break;

    default:
        /* should not get here */
        ;
    }

    return DetLayer(det, layer);
}

Variable Documentation

const int statePriorities[] [static]
Initial value:
{
      3,
         5,
       0,
        7,
          2,
         4,
       6,
     1
}

Definition at line 89 of file TrackQuality.cc.