CMS 3D CMS Logo

CmsTrackerDebugNavigator Class Reference

This class travel recursively a GeometricDet and dumps the information about type. More...

#include <Geometry/TrackerNumberingBuilder/interface/CmsTrackerDebugNavigator.h>

List of all members.

Public Member Functions

void dump (const GeometricDet *)

Private Member Functions

void iterate (const GeometricDet *, int)

Private Attributes

CmsTrackerStringToEnum _CmsTrackerStringToEnum
int numinstances [30]


Detailed Description

This class travel recursively a GeometricDet and dumps the information about type.

Definition at line 10 of file CmsTrackerDebugNavigator.h.


Member Function Documentation

void CmsTrackerDebugNavigator::dump ( const GeometricDet in  ) 

Definition at line 7 of file CmsTrackerDebugNavigator.cc.

References iterate(), k, and numinstances.

00007                                                          {
00008   edm::LogInfo("CmsTrackerDebugNavigator")<<" CmsTrackerDebugNavigator - Starting debug";
00009   for (int k=0; k<20; k++) numinstances[k]=0;
00010   iterate(in,0);
00011   
00012   for (int k=0; k<20; k++){
00013     edm::LogInfo("CmsTrackerDebugNavigator")<<" CmsTrackerDebugNavigator has found "<<numinstances[k]<<" GeometricDets at level "<<k;
00014   }
00015 }

void CmsTrackerDebugNavigator::iterate ( const GeometricDet in,
int  level 
) [private]

Definition at line 18 of file CmsTrackerDebugNavigator.cc.

References lat::endl(), i, int, k, name, and numinstances.

Referenced by dump().

00018                                                                       {
00019   static CmsTrackerStringToEnum enumName;
00020     
00021   numinstances[level]++;
00022   for (unsigned int k=0; k<(in)->components().size(); k++){
00023     std::string spaces = "";
00024     for(unsigned int i=0; (int)i<=level; i++) spaces+="  ";
00025     edm::LogInfo("CmsTrackerDebugNavigator") << level << spaces
00026                                              << "### VOLUME " << (in)->components()[k]->name().name()
00027                                              << " of type " << (in)->components()[k]->type()
00028                                              << " copy number " << (in)->components()[k]->copyno()
00029                                              << " positioned in " << (in)->name().name()
00030                                              << " global position of centre " << (in)->components()[k]->translation()
00031       //              << " rotation matrix " << (in)->components()[k]->rotation()
00032                                              << " volume = "  << (in)->components()[k]->volume()  << " cm3"
00033                                              << " density = " << (in)->components()[k]->density() << " g/cm3"
00034                                              << " weight "    << (in)->components()[k]->weight()  << " g"
00035                                              << std::endl;
00036     iterate(((in)->components())[k],level+1);
00037   }
00038   return;
00039 }


Member Data Documentation

CmsTrackerStringToEnum CmsTrackerDebugNavigator::_CmsTrackerStringToEnum [private]

Definition at line 16 of file CmsTrackerDebugNavigator.h.

int CmsTrackerDebugNavigator::numinstances[30] [private]

Definition at line 15 of file CmsTrackerDebugNavigator.h.

Referenced by dump(), and iterate().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:16:23 2009 for CMSSW by  doxygen 1.5.4