CMS 3D CMS Logo

DTSuperLayer.h
Go to the documentation of this file.
1 #ifndef DTSUPERLAYER_H
2 #define DTSUPERLAYER_H
3 
14 /* Base Class Headers */
16 
17 /* Collaborating Class Declarations */
20 
21 class DTLayer;
22 class DTChamber;
23 
24 
25 class DTSuperLayer : public GeomDet {
26 
27  public:
28 
29 /* Constructor */
30  DTSuperLayer(const DTSuperLayerId& id,
32  const DTChamber* ch=nullptr);
33 
34 /* Destructor */
35  ~DTSuperLayer() override ;
36 
37 /* Operations */
39  DTSuperLayerId id() const;
40 
41  // Which subdetector
42  SubDetector subDetector() const override {return GeomDetEnumerators::DT;}
43 
45  bool operator==(const DTSuperLayer& sl) const ;
46 
48  std::vector< const GeomDet*> components() const override;
49 
51  const GeomDet* component(DetId id) const override;
52 
54  const std::vector< const DTLayer*>& layers() const;
55 
57  void add(DTLayer* l);
58 
61  const DTChamber* chamber() const;
62 
64  const DTLayer* layer(const DTLayerId& id) const;
65 
68  const DTLayer* layer(int ilay) const;
69 
70 
71  private:
73  // The SL owns its Layer
74  std::vector< const DTLayer*> theLayers;
75  const DTChamber* theCh;
76 
77  protected:
78 
79 };
80 #endif // DTSUPERLAYER_H
81 
const DTLayer * layer(const DTLayerId &id) const
Return the layer corresponding to the given id.
Definition: DTSuperLayer.cc:68
void add(DTLayer *l)
Add layer to the SL which owns it.
Definition: DTSuperLayer.cc:59
DTSuperLayerId theId
Definition: DTSuperLayer.h:72
DTSuperLayerId id() const
Return the DetId of this SL.
Definition: DTSuperLayer.cc:36
const GeomDet * component(DetId id) const override
Return the layer with a given id in this SL.
Definition: DTSuperLayer.cc:50
SubDetector subDetector() const override
Which subdetector.
Definition: DTSuperLayer.h:42
const DTChamber * theCh
Definition: DTSuperLayer.h:75
Definition: DetId.h:18
const std::vector< const DTLayer * > & layers() const
Return the layers in the SL.
Definition: DTSuperLayer.cc:55
bool operator==(const DTSuperLayer &sl) const
True if id are the same.
Definition: DTSuperLayer.cc:40
const DTChamber * chamber() const
Definition: DTSuperLayer.cc:64
~DTSuperLayer() override
Definition: DTSuperLayer.cc:29
std::vector< const DTLayer * > theLayers
Definition: DTSuperLayer.h:74
std::vector< const GeomDet * > components() const override
Return the layers in the SL.
Definition: DTSuperLayer.cc:45
DTSuperLayer(const DTSuperLayerId &id, ReferenceCountingPointer< BoundPlane > &plane, const DTChamber *ch=0)
Definition: DTSuperLayer.cc:21