CMS 3D CMS Logo

/data/doxygen/doxygen-1.7.3/gen/CMSSW_4_2_8/src/CondFormats/SiPixelObjects/interface/SiPixelDisabledModules.h

Go to the documentation of this file.
00001 // SiPixelDisabledModules.h
00002 //
00003 // class definition to hold a list of disabled pixel modules
00004 //
00005 // M. Eads
00006 // Apr 2008
00007 
00008 #ifndef SiPixelDisabledModules_H
00009 #define SiPixelDisabledModules_H
00010 
00011 #include <vector>
00012 #include <utility>
00013 
00014 #include "DataFormats/DetId/interface/DetId.h"
00015 
00016 class SiPixelDisabledModules {
00017 
00018  public:
00019   typedef DetId disabledModuleType;
00020   typedef std::vector<disabledModuleType> disabledModuleListType;
00021 
00022   SiPixelDisabledModules() {;}
00023 
00024   // constructor from a list of disabled modules
00025   SiPixelDisabledModules(disabledModuleListType disabledModules) : theDisabledModules(disabledModules) {;}
00026 
00027   virtual ~SiPixelDisabledModules() {;}
00028 
00029   // return the list of disabled modules/ROCs
00030   disabledModuleListType getDisabledModuleList()
00031     { return theDisabledModules; }
00032 
00033   // set the list of disabled modules (current list is lost)
00034   void setDisabledModuleList(disabledModuleListType disabledModules)
00035     { theDisabledModules = disabledModules; }
00036 
00037   // add a single module to the vector of disabled modules
00038   void addDisabledModule(disabledModuleType module)
00039   { theDisabledModules.push_back(module); }
00040 
00041   // add a vector of modules to the vector of disabled modules
00042   void addDisabledModule(disabledModuleListType idVector);
00043 
00044   // remove disabled module from the list
00045   // returns false if id not in disable list, true otherwise
00046   bool removeDisabledModule(disabledModuleType module);
00047 
00048   // check if a particular module is in the disabled list
00049   // return true if it is
00050   bool isModuleDisabled(disabledModuleType module);
00051 
00052  private:
00053   disabledModuleListType theDisabledModules;
00054 
00055 }; // class SiPixelDisabledModules
00056 
00057 
00058 
00059 
00060 
00061 
00062 
00063 
00064 
00065 
00066 #endif