CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_10/src/Geometry/CSCGeometry/src/CSCGangedStripTopology.h

Go to the documentation of this file.
00001 #ifndef ORED_OFFSET_RST_H
00002 #define ORED_OFFSET_RST_H
00003 
00011 #include "Geometry/CSCGeometry/interface/CSCStripTopology.h"
00012 
00013 class CSCGangedStripTopology : public CSCStripTopology
00014 {
00015 public:
00016 
00017   CSCGangedStripTopology(const CSCStripTopology & topology, int numberOfGangedStrips ) 
00018     : CSCStripTopology(topology), theNumberOfGangedStrips(numberOfGangedStrips) {}
00019 
00020   ~CSCGangedStripTopology() {}
00021 
00026   int channel(const LocalPoint& lp) const {
00027     return (int) (RadialStripTopology::strip(lp)) % theNumberOfGangedStrips + 1;
00028   }
00029 
00034   int channel(int strip) const {
00035     while(strip > theNumberOfGangedStrips) strip -= theNumberOfGangedStrips;
00036     while(strip <= 0) strip += theNumberOfGangedStrips;
00037     return strip;
00038   }
00039 
00046   CSCStripTopology* clone() const {
00047     return new CSCGangedStripTopology(*this);
00048   }
00049 
00053   std::ostream& put ( std::ostream& os ) const {
00054     return os << "CSCGangedStripTopology";
00055   }
00056 
00057  private:
00058   int theNumberOfGangedStrips;
00059 };
00060 
00061 #endif
00062 
00063