32 if(trackerTopology.
pxfSide(detId)==1)
36 else if(trackerTopology.
pxfSide(detId)==2)
42 throw cms::Exception(
"FastSimulation/Tracking") <<
"Tracker hit for seeding in FPix seems neither on positive nor on negative disk side: "<<trackerTopology.
print(detId).c_str();
57 if(trackerTopology.
tidSide(detId)==1)
61 else if(trackerTopology.
tidSide(detId)==2)
67 throw cms::Exception(
"FastSimulation/Tracking") <<
"Tracker hit for seeding in TID seems neither on positive nor on negative disk side: "<<trackerTopology.
print(detId).c_str();
82 if(trackerTopology.
tecSide(detId)==1)
86 else if(trackerTopology.
tecSide(detId)==2)
92 throw cms::Exception(
"FastSimulation/Tracking") <<
"Tracker hit for seeding in TEC seems neither on positive nor on negative disk side: "<<trackerTopology.
print(detId).c_str();
98 throw cms::Exception(
"FastSimulation/Tracking") <<
"Cannot determine seeding layer from DetId:"<<trackerTopology.
print(detId).c_str()<<std::endl;
101 return trackingLayer;
107 if (layerSpecification.substr(0,4)==
"BPix" )
111 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(4,1).c_str());
113 else if (layerSpecification.substr(0,4)==
"FPix" )
116 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(4,1).c_str());
117 if(layerSpecification.substr(layerSpecification.size()-3)==
"pos")
121 else if (layerSpecification.substr(layerSpecification.size()-3)==
"neg")
128 <<
"FPix seeding layer configuration '"<<layerSpecification.c_str()<<
"' does not specify the side correctly!";
132 else if (layerSpecification.substr(0,3)==
"TIB")
136 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(3,1).c_str());
138 else if (layerSpecification.substr(0,4)==
"MTIB")
142 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(4,1).c_str());
145 else if (layerSpecification.substr(0,3)==
"TID")
148 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(3,1).c_str());
149 if (layerSpecification.substr(layerSpecification.size()-3)==
"pos")
153 else if (layerSpecification.substr(layerSpecification.size()-3)==
"neg")
160 <<
"TID seeding layer configuration '"<<layerSpecification.c_str()<<
"' does not specify the side correctly!";
163 else if (layerSpecification.substr(0,4)==
"MTID")
166 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(4,1).c_str());
167 if (layerSpecification.substr(layerSpecification.size()-3)==
"pos")
171 else if (layerSpecification.substr(layerSpecification.size()-3)==
"neg")
178 <<
"MTID seeding layer configuration '"<<layerSpecification.c_str()<<
"' does not specify the side correctly!";
181 else if (layerSpecification.substr(0,3)==
"TOB" )
185 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(3,1).c_str());
187 else if (layerSpecification.substr(0,4)==
"MTOB" )
191 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(4,1).c_str());
193 else if (layerSpecification.substr(0,3)==
"TEC" )
196 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(3,1).c_str());
197 if (layerSpecification.substr(layerSpecification.size()-3)==
"pos")
201 else if (layerSpecification.substr(layerSpecification.size()-3)==
"neg")
208 <<
"TEC seeding layer configuration '"<<layerSpecification.c_str()<<
"' does not specify the side correctly!";
213 else if (layerSpecification.substr(0,4)==
"MTEC" )
216 trackingLayer.
_layerNumber = std::atoi(layerSpecification.substr(4,1).c_str());
217 if (layerSpecification.substr(layerSpecification.size()-3)==
"pos")
221 else if (layerSpecification.substr(layerSpecification.size()-3)==
"neg")
228 <<
"MTEC seeding layer configuration '"<<layerSpecification.c_str()<<
"' does not specify the side correctly!";
234 <<
"Bad data naming in seeding layer configuration." 235 <<
"no case sensitive name of ['BPix','FPix','TIB','MTIB','TID','MTID','TOB','TEC','MTEC'] matches '"<<layerSpecification.c_str()<<
"'";
239 return trackingLayer;
244 std::stringstream ss;
287 std::stringstream ss;
unsigned int getSubDetNumber() const
unsigned int tibLayer(const DetId &id) const
unsigned int getLayerNumber() const
unsigned int pxfDisk(const DetId &id) const
0: Unidentified isolated particle
static TrackingLayer createFromDetId(const DetId &detId, const TrackerTopology &trackerTopology)
std::string toIdString() const
unsigned int tidWheel(const DetId &id) const
std::string print(DetId detid) const
static const eqfct _eqfct
unsigned int tidSide(const DetId &id) const
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
unsigned int getSideNumber() const
static TrackingLayer createFromString(std::string layerSpecification)
unsigned int _layerNumber
std::string toString() const
unsigned int pxbLayer(const DetId &id) const
unsigned int pxfSide(const DetId &id) const
unsigned int tecWheel(const DetId &id) const
unsigned int tobLayer(const DetId &id) const
unsigned int tecSide(const DetId &id) const