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 class DTSuperLayer : public GeomDet {
25 public:
26  /* Constructor */
27  DTSuperLayer(const DTSuperLayerId& id, ReferenceCountingPointer<BoundPlane>& plane, const DTChamber* ch = nullptr);
28 
29  /* Destructor */
30  ~DTSuperLayer() override;
31 
32  /* Operations */
34  DTSuperLayerId id() const;
35 
36  // Which subdetector
37  SubDetector subDetector() const override { return GeomDetEnumerators::DT; }
38 
40  bool operator==(const DTSuperLayer& sl) const;
41 
43  std::vector<const GeomDet*> components() const override;
44 
46  const GeomDet* component(DetId id) const override;
47 
49  const std::vector<const DTLayer*>& layers() const;
50 
52  void add(DTLayer* l);
53 
56  const DTChamber* chamber() const;
57 
59  const DTLayer* layer(const DTLayerId& id) const;
60 
63  const DTLayer* layer(int ilay) const;
64 
65 private:
67  // The SL owns its Layer
68  std::vector<const DTLayer*> theLayers;
69  const DTChamber* theCh;
70 
71 protected:
72 };
73 #endif // DTSUPERLAYER_H
SubDetector subDetector() const override
Which subdetector.
Definition: DTSuperLayer.h:37
std::vector< const DTLayer * > theLayers
Definition: DTSuperLayer.h:68
void add(DTLayer *l)
Add layer to the SL which owns it.
Definition: DTSuperLayer.cc:47
const std::vector< const DTLayer * > & layers() const
Return the layers in the SL.
Definition: DTSuperLayer.cc:45
const DTChamber * chamber() const
Definition: DTSuperLayer.cc:52
DTSuperLayerId theId
Definition: DTSuperLayer.h:66
DTSuperLayer(const DTSuperLayerId &id, ReferenceCountingPointer< BoundPlane > &plane, const DTChamber *ch=nullptr)
Definition: DTSuperLayer.cc:21
const DTLayer * layer(const DTLayerId &id) const
Return the layer corresponding to the given id.
Definition: DTSuperLayer.cc:54
const DTChamber * theCh
Definition: DTSuperLayer.h:69
Definition: DetId.h:17
const GeomDet * component(DetId id) const override
Return the layer with a given id in this SL.
Definition: DTSuperLayer.cc:43
bool operator==(const DTSuperLayer &sl) const
True if id are the same.
Definition: DTSuperLayer.cc:36
~DTSuperLayer() override
Definition: DTSuperLayer.cc:27
DTSuperLayerId id() const
Return the DetId of this SL.
Definition: DTSuperLayer.cc:34
std::vector< const GeomDet * > components() const override
Return the layers in the SL.
Definition: DTSuperLayer.cc:39