CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
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/SiPixelDetId/interface/PixelSubdetector.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "Geometry/Records/interface/IdealGeometryRecord.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.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

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 83 of file TrackQuality.cc.

Function Documentation

DetLayer getDetLayer ( DetId  detId,
const TrackerTopology tTopo 
)

Definition at line 98 of file TrackQuality.cc.

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

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

99 {
101  short int layer = 0;
102 
103  switch (detId.det())
104  {
105  case DetId::Tracker:
106  layer=tTopo->layer(detId);
107  break;
108 
109  case DetId::Muon:
110  switch (detId.subdetId())
111  {
112  case MuonSubdetId::DT:
114  layer = DTLayerId(detId).layer();
115  break;
116 
117  case MuonSubdetId::CSC:
119  layer = CSCDetId(detId).layer();
120  break;
121 
122  case MuonSubdetId::RPC:
123  if (RPCDetId(detId).region())
125  else
127  layer = RPCDetId(detId).layer();
128  break;
129 
130  default:
131  /* should not get here */
132  ;
133  }
134  break;
135 
136  default:
137  /* should not get here */
138  ;
139  }
140 
141  return DetLayer(det, layer);
142 }
std::pair< TrackQuality::Layer::SubDet, short int > DetLayer
Definition: TrackQuality.cc:83
static const int CSC
Definition: MuonSubdetId.h:13
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:37
unsigned int layer(const DetId &id) const
static const int RPC
Definition: MuonSubdetId.h:14
static const int DT
Definition: MuonSubdetId.h:12
Detector det() const
get the detector field from this detid
Definition: DetId.h:35

Variable Documentation

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

Definition at line 86 of file TrackQuality.cc.