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 Member Functions
CmsDetConstruction Class Reference

#include <CmsDetConstruction.h>

Inheritance diagram for CmsDetConstruction:
CmsTrackerLevelBuilder CmsTrackerAbstractConstruction

Public Member Functions

void buildComponent (DDFilteredView &, GeometricDet *, std::string)
 
- Public Member Functions inherited from CmsTrackerLevelBuilder
virtual void build (DDFilteredView &, GeometricDet *, std::string)
 
virtual ~CmsTrackerLevelBuilder ()
 

Private Member Functions

void buildDets (DDFilteredView &, GeometricDet *, std::string)
 
void buildSmallDets (DDFilteredView &, GeometricDet *, std::string)
 

Additional Inherited Members

- Protected Attributes inherited from CmsTrackerLevelBuilder
CmsTrackerStringToEnum theCmsTrackerStringToEnum
 

Detailed Description

Adds GeometricDets representing final modules to the previous level

Definition at line 9 of file CmsDetConstruction.h.

Member Function Documentation

void CmsDetConstruction::buildComponent ( DDFilteredView fv,
GeometricDet mother,
std::string  attribute 
)
virtual

Implements CmsTrackerLevelBuilder.

Definition at line 5 of file CmsDetConstruction.cc.

References GeometricDet::addComponent(), buildSmallDets(), DDFilteredView::firstChild(), ExtractStringFromDDD::getString(), GeometricDet::mergedDet, DDFilteredView::nextSibling(), DDFilteredView::parent(), CmsTrackerLevelBuilder::theCmsTrackerStringToEnum, and CmsTrackerStringToEnum::type().

Referenced by CmsTrackerPanelBuilder::buildComponent(), CmsTrackerStringBuilder::buildComponent(), CmsTrackerRodBuilder::buildComponent(), CmsTrackerRingBuilder::buildComponent(), and CmsTrackerLadderBuilder::buildComponent().

8  {
9 
10  //
11  // at this level I check whether it is a merged detector or not
12  //
13 
16  //
17  // I have to go one step lower ...
18  //
19  bool dodets = fv.firstChild(); // descend to the first Layer
20  while (dodets) {
21  buildSmallDets(fv,det,attribute);
22  dodets = fv.nextSibling(); // go to next layer
23  /*
24  Add algo to sort the merged DET
25  */
26  }
27  fv.parent();
28  }
29 
30  mother->addComponent(det);
31 }
static std::string getString(std::string const &, DDFilteredView *)
bool parent()
set the current node to the parent node ...
void buildSmallDets(DDFilteredView &, GeometricDet *, std::string)
void addComponent(GeometricDet *)
bool nextSibling()
set the current node to the next sibling ...
bool firstChild()
set the current node to the first child ...
GeometricDet::GeometricEnumType type(std::string const &) const
CmsTrackerStringToEnum theCmsTrackerStringToEnum
void CmsDetConstruction::buildDets ( DDFilteredView ,
GeometricDet ,
std::string   
)
private
void CmsDetConstruction::buildSmallDets ( DDFilteredView fv,
GeometricDet mother,
std::string  attribute 
)
private

Definition at line 33 of file CmsDetConstruction.cc.

References GeometricDet::addComponent(), ExtractStringFromDDD::getString(), GeometricDet::setGeographicalID(), AlCaHLTBitMon_QueryRunRegistry::string, groupFilesInBlocks::temp, CmsTrackerLevelBuilder::theCmsTrackerStringToEnum, and CmsTrackerStringToEnum::type().

Referenced by buildComponent().

36  {
37 
38  GeometricDet * det =
39  new GeometricDet(&fv,
41  static const std::string stereo = "TrackerStereoDetectors";
42  if (ExtractStringFromDDD::getString(stereo,&fv) == "true"){
43  uint32_t temp = 1;
44  det->setGeographicalID(DetId(temp));
45  }else{
46  uint32_t temp = 2;
47  det->setGeographicalID(DetId(temp));
48  }
49 
50  mother->addComponent(det);
51 }
static std::string getString(std::string const &, DDFilteredView *)
void setGeographicalID(DetId id) const
Definition: GeometricDet.h:74
void addComponent(GeometricDet *)
Definition: DetId.h:20
GeometricDet::GeometricEnumType type(std::string const &) const
CmsTrackerStringToEnum theCmsTrackerStringToEnum