CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_1_8_patch9/src/Geometry/ForwardGeometry/interface/ZdcTopology.h

Go to the documentation of this file.
00001 #ifndef Geometry_ForwardGeometry_ZdcTopology_H
00002 #define Geometry_ForwardGeometry_ZdcTopology_H 1
00003 
00004 #include <vector>
00005 #include "DataFormats/HcalDetId/interface/HcalZDCDetId.h"
00006 #include "Geometry/CaloTopology/interface/CaloSubdetectorTopology.h"
00007 
00015 class ZdcTopology : public CaloSubdetectorTopology {
00016 public:
00017 
00018   ZdcTopology();
00020   void exclude(const HcalZDCDetId& id);
00022   void exclude(int zside); 
00024   void exclude(int zside, HcalZDCDetId::Section section);
00026   int exclude(int zside, HcalZDCDetId::Section section, int ich1, int ich2);
00027 
00029   virtual bool valid(const HcalZDCDetId& id) const;
00030 
00032   virtual std::vector<DetId> transverse(const DetId& id) const;
00033   
00035   virtual std::vector<DetId> longitudinal(const DetId& id) const;
00036 
00037   //** I have to put this here since they inherit from CaloSubdetectorTopology
00038   virtual std::vector<DetId> east(const DetId& id) const;
00039   virtual std::vector<DetId> west(const DetId& id) const; 
00040   virtual std::vector<DetId> north(const DetId& id) const;
00041   virtual std::vector<DetId> south(const DetId& id) const;
00042   virtual std::vector<DetId> up(const DetId& id) const;
00043   virtual std::vector<DetId> down(const DetId& id) const;
00044   
00045   
00046   // how many channels (deph) for a given section
00047   int ncells(HcalZDCDetId::Section section) const;
00048 
00049   //return first and last cell of each section
00050   int firstCell(HcalZDCDetId::Section section)const;  
00051   int lastCell(HcalZDCDetId::Section section)const;
00052  
00053  private:
00054   
00055   bool validRaw(const HcalZDCDetId& id) const;
00056   
00057   std::vector<HcalZDCDetId> exclusionList_;
00058   
00059   bool excludeEM_, excludeHAD_, excludeLUM_, excludeZP_, excludeZN_;
00060   
00061   int firstEMModule_, lastEMModule_, firstHADModule_, lastHADModule_, 
00062     firstLUMModule_, lastLUMModule_;
00063    
00064   bool isExcluded(const HcalZDCDetId& id) const;
00065   
00066   int firstEMModule() const {return firstEMModule_;}
00067   int firstHADModule() const {return firstHADModule_;}  
00068   int firstLUMModule() const {return firstLUMModule_;}
00069   int lastEMModule()  const {return lastEMModule_;}
00070   int lastHADModule() const {return lastHADModule_;}  
00071   int lastLUMModule() const {return lastLUMModule_;}
00072 
00073 };
00074 
00075 
00076 #endif