CMS 3D CMS Logo

Private Member Functions

CmsTrackerStringBuilder Class Reference

#include <CmsTrackerStringBuilder.h>

Inheritance diagram for CmsTrackerStringBuilder:
CmsTrackerLevelBuilder CmsTrackerAbstractConstruction

List of all members.

Private Member Functions

virtual void buildComponent (DDFilteredView &, GeometricDet *, std::string)
virtual void sortNS (DDFilteredView &, GeometricDet *)

Detailed Description

Class which constructs TIB strings

Definition at line 10 of file CmsTrackerStringBuilder.h.


Member Function Documentation

void CmsTrackerStringBuilder::buildComponent ( DDFilteredView fv,
GeometricDet g,
std::string  s 
) [private, virtual]

Implements CmsTrackerLevelBuilder.

Definition at line 11 of file CmsTrackerStringBuilder.cc.

References CmsDetConstruction::buildComponent().

                                                                                            {
  CmsDetConstruction theCmsDetConstruction;
  theCmsDetConstruction.buildComponent(fv,g,s);  
}
void CmsTrackerStringBuilder::sortNS ( DDFilteredView fv,
GeometricDet det 
) [private, virtual]

Reimplemented from CmsTrackerLevelBuilder.

Definition at line 16 of file CmsTrackerStringBuilder.cc.

References GeometricDet::addComponents(), GeometricDet::clearComponents(), GeometricDet::components(), and i.

                                                                         {
  GeometricDet::GeometricDetContainer comp = det->components();

  std::stable_sort(comp.begin(),comp.end(),LessModZ()); 
  
  if(comp.size()){
    for(uint32_t i=0; i<comp.size();i++){
      comp[i]->setGeographicalID(DetId(i+1));
    }
    det->clearComponents();
    det->addComponents(comp);
  }else{
       edm::LogError("CmsTrackerStringBuilder")<<"Where are the String's modules?";
  }
}