CMS 3D CMS Logo

Typedefs | Functions | Variables
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/MuonDetId/interface/CSCDetId.h"
#include "DataFormats/MuonDetId/interface/DTLayerId.h"
#include "DataFormats/MuonDetId/interface/MuonSubdetId.h"
#include "DataFormats/MuonDetId/interface/RPCDetId.h"
#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "Geometry/Records/interface/IdealGeometryRecord.h"
#include "DataFormats/TrackReco/interface/Track.h"
#include "DataFormats/TrackReco/interface/TrackFwd.h"
#include "DataFormats/TrackingRecHit/interface/TrackingRecHit.h"
#include "DataFormats/TrackingRecHit/interface/TrackingRecHitFwd.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

DetLayer getDetLayer (DetId detId, const TrackerTopology *tTopo)
 

Variables

static const int statePriorities []
 

Typedef Documentation

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

Definition at line 77 of file TrackQuality.cc.

Function Documentation

DetLayer getDetLayer ( DetId  detId,
const TrackerTopology tTopo 
)

Definition at line 90 of file TrackQuality.cc.

References MuonSubdetId::CSC, DetId::det(), MuonSubdetId::DT, TrackQuality::Layer::Invalid, DTLayerId::layer(), CSCDetId::layer(), RPCDetId::layer(), TrackerTopology::layer(), DetId::Muon, TrackQuality::Layer::MuonCSC, TrackQuality::Layer::MuonDT, TrackQuality::Layer::MuonRPCBarrel, TrackQuality::Layer::MuonRPCEndcap, MuonSubdetId::RPC, DetId::subdetId(), and DetId::Tracker.

Referenced by TrackQuality::evaluate(), and MeasurementByLayerGrouper::operator()().

90  {
92  short int layer = 0;
93 
94  switch (detId.det()) {
95  case DetId::Tracker:
96  layer = tTopo->layer(detId);
97  break;
98 
99  case DetId::Muon:
100  switch (detId.subdetId()) {
101  case MuonSubdetId::DT:
103  layer = DTLayerId(detId).layer();
104  break;
105 
106  case MuonSubdetId::CSC:
108  layer = CSCDetId(detId).layer();
109  break;
110 
111  case MuonSubdetId::RPC:
112  if (RPCDetId(detId).region())
114  else
116  layer = RPCDetId(detId).layer();
117  break;
118 
119  default:
120  /* should not get here */
121  ;
122  }
123  break;
124 
125  default:
126  /* should not get here */
127  ;
128  }
129 
130  return DetLayer(det, layer);
131 }
std::pair< TrackQuality::Layer::SubDet, short int > DetLayer
Definition: TrackQuality.cc:77
int layer() const
Return the layer number.
Definition: DTLayerId.h:53
int layer() const
Definition: CSCDetId.h:61
static const int CSC
Definition: MuonSubdetId.h:13
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:41
int layer() const
Definition: RPCDetId.h:108
unsigned int layer(const DetId &id) const
static const int RPC
Definition: MuonSubdetId.h:14
static const int DT
Definition: MuonSubdetId.h:12
constexpr Detector det() const
get the detector field from this detid
Definition: DetId.h:39

Variable Documentation

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

Definition at line 80 of file TrackQuality.cc.