CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CSCLayer.h
Go to the documentation of this file.
1 #ifndef Geometry_CSCGeometry_CSCLayer_H
2 #define Geometry_CSCGeometry_CSCLayer_H
3 
13 
20 
21 //#include <boost/shared_ptr.hpp>
22 //typedef boost::shared_ptr<CSCChamber> Pointer2Chamber;
23 
24 class CSCLayer : public GeomDetUnit {
25 
26 public:
27 
29  GeomDetUnit( sp ), theId( id ), theChamber( ch ), theGeometry( geo ) {
30  setDetId(id);
31 }
32 
33  const GeomDetType& type() const { return chamber()->type(); }
34 
35  const Topology& topology() const { return *(geometry()->topology()); }
36 
37 
42  CSCDetId id() const { return theId; }
43 
47  const CSCLayerGeometry* geometry() const { return theGeometry; }
48 
52  const CSCChamber* chamber() const { return theChamber; }
53 
58  GlobalPoint centerOfStrip(int strip) const;
59 
64  GlobalPoint centerOfWireGroup(int wireGroup) const;
65 
66 private:
67 
69 
70  const CSCChamber* theChamber; // NOT owned
71  // Pointer2Chamber theChamber; // use a smart pointer instead
72 
73  // Local geometry is handled by the LayerGeometry
74  // but only the Layer itself knows how to transform to the
75  // global frame so global calculations are handled by the
76  // Layer not the LayerGeometry.
77  const CSCLayerGeometry* theGeometry; // must have topology()
78 };
79 
80 #endif // Geometry_CSCGeometry_CSCLayer_H
CSCLayer(const BoundPlane::BoundPlanePointer sp, CSCDetId id, const CSCChamber *ch, const CSCLayerGeometry *geo)
Definition: CSCLayer.h:28
const GeomDetType & type() const
Definition: CSCChamber.h:34
void setDetId(DetId id)
Definition: GeomDet.h:114
CSCDetId id() const
Definition: CSCLayer.h:42
const Topology & topology() const
Definition: CSCLayer.h:35
const GeomDetType & type() const
Definition: CSCLayer.h:33
GlobalPoint centerOfWireGroup(int wireGroup) const
Definition: CSCLayer.cc:10
const CSCChamber * theChamber
Definition: CSCLayer.h:70
GlobalPoint centerOfStrip(int strip) const
Definition: CSCLayer.cc:4
const CSCStripTopology * topology() const
const CSCLayerGeometry * theGeometry
Definition: CSCLayer.h:77
Definition: sp.h:21
const CSCChamber * chamber() const
Definition: CSCLayer.h:52
const CSCLayerGeometry * geometry() const
Definition: CSCLayer.h:47
CSCDetId theId
Definition: CSCLayer.h:68