CMS 3D CMS Logo

MTDDetLayerGeometry.h
Go to the documentation of this file.
1 #ifndef DetLayers_MTDDetLayerGeometry_h
2 #define DetLayers_MTDDetLayerGeometry_h
3 
14 #include <vector>
15 #include <map>
16 
17 class DetLayer;
18 
20  public:
21 
24 
26 
28  ~MTDDetLayerGeometry() override;
29 
31  const std::vector<const DetLayer*>& allBarrelLayers() const;
32 
34  const std::vector<const DetLayer*>& allEndcapLayers() const;
35 
37  const std::vector<const DetLayer*>& allForwardLayers() const;
38 
40  const std::vector<const DetLayer*>& allBackwardLayers() const;
41 
43  const std::vector<const DetLayer*>& allBTLLayers() const;
44 
46  const std::vector<const DetLayer*>& allETLLayers() const;
47 
49  const std::vector<const DetLayer*>& allLayers() const;
50 
52  const DetLayer* idToLayer(const DetId& detId) const override;
53 
54  private:
58  void addETLLayers(const std::pair<std::vector<DetLayer*>, std::vector<DetLayer*> >& etllayers);
59 
60  //. Add BTL layers; dtlayers is ASSUMED to be sorted inside-out
61  void addBTLLayers(const std::vector<DetLayer*>& btllayers);
62 
63  DetId makeDetLayerId(const DetLayer* detLayer) const;
64 
65  void sortLayers();
66 
67  std::vector<const DetLayer*> etlLayers_fw;
68  std::vector<const DetLayer*> etlLayers_bk;
69  std::vector<const DetLayer*> etlLayers_all;
70 
72  std::vector<const DetLayer*> btlLayers;
73  std::vector<const DetLayer*> allForward;
74  std::vector<const DetLayer*> allBackward;
75  std::vector<const DetLayer*> allEndcap;
76  std::vector<const DetLayer*> allBarrel;
77  std::vector<const DetLayer*> allDetLayers;
78 
79  std::map<DetId,const DetLayer*> detLayersMap;
80 };
81 #endif
82 
std::vector< const DetLayer * > etlLayers_fw
const std::vector< const DetLayer * > & allLayers() const
return all DetLayers (barrel + endcap), -Z to +Z
MTDDetLayerGeometry()
Constructor.
DetId makeDetLayerId(const DetLayer *detLayer) const
const std::vector< const DetLayer * > & allEndcapLayers() const
return all endcap layers
void addBTLLayers(const std::vector< DetLayer * > &btllayers)
~MTDDetLayerGeometry() override
Destructor.
std::vector< const DetLayer * > etlLayers_bk
const std::vector< const DetLayer * > & allBTLLayers() const
return the BTL DetLayers (barrel), inside-out
const std::vector< const DetLayer * > & allBackwardLayers() const
return all endcap layers
std::vector< const DetLayer * > etlLayers_all
void addETLLayers(const std::pair< std::vector< DetLayer * >, std::vector< DetLayer * > > &etllayers)
const std::vector< const DetLayer * > & allETLLayers() const
return the ETL DetLayers (endcap), -Z to +Z
std::vector< const DetLayer * > allBackward
std::vector< const DetLayer * > allEndcap
std::vector< const DetLayer * > allBarrel
Definition: DetId.h:18
const DetLayer * idToLayer(const DetId &detId) const override
return the DetLayer which correspond to a certain DetId
std::vector< const DetLayer * > allDetLayers
const std::vector< const DetLayer * > & allForwardLayers() const
return all endcap layers
const std::vector< const DetLayer * > & allBarrelLayers() const
return all barrel layers
std::vector< const DetLayer * > allForward
std::vector< const DetLayer * > btlLayers
std::map< DetId, const DetLayer * > detLayersMap