CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
DTSuperLayer Class Reference

#include <DTSuperLayer.h>

Inheritance diagram for DTSuperLayer:
GeomDet

Public Member Functions

void add (DTLayer *l)
 Add layer to the SL which owns it. More...
 
const DTChamberchamber () const
 
virtual const GeomDetcomponent (DetId id) const
 Return the layer with a given id in this SL. More...
 
virtual std::vector< const
GeomDet * > 
components () const
 Return the layers in the SL. More...
 
 DTSuperLayer (DTSuperLayerId id, ReferenceCountingPointer< BoundPlane > &plane, const DTChamber *ch=0)
 
DTSuperLayerId id () const
 Return the DetId of this SL. More...
 
const DTLayerlayer (DTLayerId id) const
 Return the layer corresponding to the given id. More...
 
const DTLayerlayer (int ilay) const
 
const std::vector< const
DTLayer * > & 
layers () const
 Return the layers in the SL. More...
 
bool operator== (const DTSuperLayer &sl) const
 True if id are the same. More...
 
virtual SubDetector subDetector () const
 Which subdetector. More...
 
virtual ~DTSuperLayer ()
 
- Public Member Functions inherited from GeomDet
AlignmentPositionError const * alignmentPositionError () const
 Return pointer to alignment errors. More...
 
DetId geographicalId () const
 The label of this GeomDet. More...
 
 GeomDet (Plane *plane)
 
 GeomDet (const ReferenceCountingPointer< Plane > &plane)
 
int index () const
 
virtual bool isLeaf () const
 is a Unit More...
 
const Surface::PositionTypeposition () const
 The position (origin of the R.F.) More...
 
const Surface::RotationTyperotation () const
 The rotation defining the local R.F. More...
 
void setIndex (int i)
 
const PlanespecificSurface () const
 Same as surface(), kept for backward compatibility. More...
 
const Planesurface () const
 The nominal surface of the GeomDet. More...
 
virtual const SurfaceDeformationsurfaceDeformation () const
 
GlobalPoint toGlobal (const Local2DPoint &lp) const
 Conversion to the global R.F. from the R.F. of the GeomDet. More...
 
GlobalPoint toGlobal (const Local3DPoint &lp) const
 Conversion to the global R.F. from the R.F. of the GeomDet. More...
 
GlobalVector toGlobal (const LocalVector &lv) const
 Conversion to the global R.F. from the R.F. of the GeomDet. More...
 
LocalPoint toLocal (const GlobalPoint &gp) const
 Conversion to the R.F. of the GeomDet. More...
 
LocalVector toLocal (const GlobalVector &gv) const
 Conversion to the R.F. of the GeomDet. More...
 
virtual const Topologytopology () const
 
virtual const GeomDetTypetype () const
 
virtual ~GeomDet ()
 

Private Attributes

const DTChambertheCh
 
DTSuperLayerId theId
 
std::vector< const DTLayer * > theLayers
 

Additional Inherited Members

- Public Types inherited from GeomDet
typedef
GeomDetEnumerators::SubDetector 
SubDetector
 
- Protected Member Functions inherited from GeomDet
void setDetId (DetId id)
 
- Protected Attributes inherited from GeomDet
AlignmentPositionErrortheAlignmentPositionError
 

Detailed Description

Model of a superlayer in Muon Drift Tube chambers.

A superlayer is composed by 4 staggered DTLayer s.

Author
Stefano Lacaprara - INFN Padova stefa.nosp@m.no.l.nosp@m.acapr.nosp@m.ara@.nosp@m.pd.in.nosp@m.fn.i.nosp@m.t

Definition at line 25 of file DTSuperLayer.h.

Constructor & Destructor Documentation

DTSuperLayer::DTSuperLayer ( DTSuperLayerId  id,
ReferenceCountingPointer< BoundPlane > &  plane,
const DTChamber ch = 0 
)

Definition at line 21 of file DTSuperLayer.cc.

References GeomDet::setDetId().

23  :
24  GeomDet(plane), theId(id) , theLayers(4,(const DTLayer*)0), theCh(ch) {
25  setDetId(id);
26 }
void setDetId(DetId id)
Definition: GeomDet.h:114
DTSuperLayerId theId
Definition: DTSuperLayer.h:72
const DTChamber * theCh
Definition: DTSuperLayer.h:75
std::vector< const DTLayer * > theLayers
Definition: DTSuperLayer.h:74
GeomDet(Plane *plane)
Definition: GeomDet.cc:5
DTSuperLayer::~DTSuperLayer ( )
virtual

Definition at line 29 of file DTSuperLayer.cc.

References theLayers.

29  {
30  for (std::vector<const DTLayer*>::const_iterator il=theLayers.begin();
31  il!=theLayers.end(); ++il) delete (*il);
32 }
std::vector< const DTLayer * > theLayers
Definition: DTSuperLayer.h:74

Member Function Documentation

void DTSuperLayer::add ( DTLayer l)

Add layer to the SL which owns it.

Definition at line 59 of file DTSuperLayer.cc.

References DTLayer::id(), cmsLHEtoEOSManager::l, DTLayerId::layer(), and theLayers.

Referenced by DTGeometryBuilderFromDDD::buildLayer(), DTGeometryBuilderFromCondDB::buildLayer(), and counter.Counter::register().

59  {
60  // theLayers size is preallocated.
61  theLayers[l->id().layer()-1] = l;
62 }
DTLayerId id() const
Return the DetId of this SL.
Definition: DTLayer.cc:46
int layer() const
Return the layer number.
Definition: DTLayerId.h:53
std::vector< const DTLayer * > theLayers
Definition: DTSuperLayer.h:74
const DTChamber * DTSuperLayer::chamber ( ) const

Return the chamber this SL belongs to (0 if any, eg if a SL is built on his own)

Definition at line 64 of file DTSuperLayer.cc.

References theCh.

Referenced by DTLayer::chamber(), and geometryXMLparser.CSCAlignable::index().

64  {
65  return theCh;
66 }
const DTChamber * theCh
Definition: DTSuperLayer.h:75
const GeomDet * DTSuperLayer::component ( DetId  id) const
virtual

Return the layer with a given id in this SL.

Reimplemented from GeomDet.

Definition at line 50 of file DTSuperLayer.cc.

References DTLayerId, and layer().

50  {
51  return layer(DTLayerId(id.rawId()));
52 }
const DTLayer * layer(DTLayerId id) const
Return the layer corresponding to the given id.
Definition: DTSuperLayer.cc:68
std::vector< const GeomDet * > DTSuperLayer::components ( ) const
virtual

Return the layers in the SL.

Reimplemented from GeomDet.

Definition at line 45 of file DTSuperLayer.cc.

References theLayers.

45  {
46  return std::vector<const GeomDet*>(theLayers.begin(), theLayers.end());
47 }
std::vector< const DTLayer * > theLayers
Definition: DTSuperLayer.h:74
DTSuperLayerId DTSuperLayer::id ( void  ) const
const DTLayer * DTSuperLayer::layer ( DTLayerId  id) const

Return the layer corresponding to the given id.

Definition at line 68 of file DTSuperLayer.cc.

References theId.

Referenced by component(), DTTrigGeom::getGeom(), geometryXMLparser.DTAlignable::index(), geometryXMLparser.CSCAlignable::index(), DTTMax::InfoLayer::InfoLayer(), DTClusterer::initHits(), DTTrigGeom::localPosition(), and DTTrigGeom::tubePosInCh().

68  {
69  if (id.superlayerId()!=theId) return 0; // not in this SL!
70  return layer(id.layer());
71 }
DTSuperLayerId theId
Definition: DTSuperLayer.h:72
const DTLayer * layer(DTLayerId id) const
Return the layer corresponding to the given id.
Definition: DTSuperLayer.cc:68
const DTLayer * DTSuperLayer::layer ( int  ilay) const

Return the given layer. Layers are numbered 1-4.

Definition at line 73 of file DTSuperLayer.cc.

References theLayers.

Referenced by geometryXMLparser.DTAlignable::index(), and geometryXMLparser.CSCAlignable::index().

73  {
74  if ((ilay>=1) && (ilay<=4)) {
75  return theLayers[ilay-1];
76  } else {
77  return 0;
78  }
79 }
std::vector< const DTLayer * > theLayers
Definition: DTSuperLayer.h:74
const std::vector< const DTLayer * > & DTSuperLayer::layers ( ) const

Return the layers in the SL.

Definition at line 55 of file DTSuperLayer.cc.

References theLayers.

55  {
56  return theLayers;
57 }
std::vector< const DTLayer * > theLayers
Definition: DTSuperLayer.h:74
bool DTSuperLayer::operator== ( const DTSuperLayer sl) const

True if id are the same.

Definition at line 40 of file DTSuperLayer.cc.

References id().

40  {
41  return id()==sl.id();
42 }
DTSuperLayerId id() const
Return the DetId of this SL.
Definition: DTSuperLayer.cc:36
virtual SubDetector DTSuperLayer::subDetector ( ) const
inlinevirtual

Which subdetector.

Reimplemented from GeomDet.

Definition at line 42 of file DTSuperLayer.h.

References GeomDetEnumerators::DT.

Member Data Documentation

const DTChamber* DTSuperLayer::theCh
private

Definition at line 75 of file DTSuperLayer.h.

Referenced by chamber().

DTSuperLayerId DTSuperLayer::theId
private

Definition at line 72 of file DTSuperLayer.h.

Referenced by id(), and layer().

std::vector< const DTLayer*> DTSuperLayer::theLayers
private

Definition at line 74 of file DTSuperLayer.h.

Referenced by add(), components(), layer(), layers(), and ~DTSuperLayer().