![]() |
![]() |
#include <MagneticField/Layers/interface/MagBRod.h>
Public Member Functions | |
MagVolume * | findVolume (const GlobalPoint &gp, double tolerance) const |
Find the volume containing a point, with a given tolerance. | |
MagBRod (std::vector< MagBSlab * > &slabs, Geom::Phi< float > phiMin) | |
Constructor. | |
Geom::Phi< float > | minPhi () const |
Phi of rod start. | |
virtual | ~MagBRod () |
Destructor. | |
Private Attributes | |
MagBinFinders::GeneralBinFinderInZ < double > * | theBinFinder |
Geom::Phi< float > | thePhiMin |
std::vector< MagBSlab * > | theSlabs |
It is part of the hierarchical organisation of barrel volumes:
A barrel layer (MagBLayer) groups volumes at the same distance to the origin. It consists of 12 sectors in phi (MagBSector). Each sector consists of one or more rods (MagBRods) of equal width in phi. Rods consist of one or more slabs (MagBSlab); each one consisting of one or, in few cases, several volumes with the same lenght in Z.
Definition at line 27 of file MagBRod.h.
MagBRod::~MagBRod | ( | ) | [virtual] |
Destructor.
Definition at line 42 of file MagBRod.cc.
References theBinFinder, and theSlabs.
00042 { 00043 delete theBinFinder; 00044 00045 for (vector<MagBSlab *>::const_iterator islab = theSlabs.begin(); 00046 islab != theSlabs.end(); ++islab) { 00047 delete (*islab); 00048 } 00049 }
MagVolume * MagBRod::findVolume | ( | const GlobalPoint & | gp, | |
double | tolerance | |||
) | const |
Find the volume containing a point, with a given tolerance.
Definition at line 51 of file MagBRod.cc.
References MagBinFinders::GeneralBinFinderInZ< T >::binIndex(), GenMuonPlsPt100GeV_cfg::cout, verbose::debugOut, lat::endl(), HLT_VtxMuL3::result, theBinFinder, theSlabs, and PV3DBase< T, PVType, FrameType >::z().
00051 { 00052 MagVolume * result = 0; 00053 float Z = gp.z(); 00054 00055 int bin = 0; 00056 if (theBinFinder!=0) { // true if there is > 1 bin 00057 bin = theBinFinder->binIndex(Z); 00058 } 00059 00060 // TOFIX 00061 if (verbose::debugOut) cout << " Trying slab at Z " << theSlabs[bin]->minZ() 00062 << " " << Z << endl ; 00063 result = theSlabs[bin]->findVolume(gp, tolerance); 00064 // TOFIX 00065 if (verbose::debugOut) cout << "***In guessed bslab" 00066 << (result==0? " failed " : " OK ") <<endl; 00067 00068 return result; 00069 }
Geom::Phi<float> MagBRod::minPhi | ( | ) | const [inline] |
MagBinFinders::GeneralBinFinderInZ<double>* MagBRod::theBinFinder [private] |
Geom::Phi<float> MagBRod::thePhiMin [private] |
std::vector<MagBSlab*> MagBRod::theSlabs [private] |