CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_9_patch3/src/CondFormats/L1TObjects/interface/L1MuDTQualPatternLut.h

Go to the documentation of this file.
00001 //-------------------------------------------------
00002 //
00015 //
00016 //--------------------------------------------------
00017 #ifndef L1MUDT_QUALPATTERN_LUT_H
00018 #define L1MUDT_QUALPATTERN_LUT_H
00019 
00020 //---------------
00021 // C++ Headers --
00022 //---------------
00023 
00024 #include <vector>
00025 #include <map>
00026 
00027 //----------------------
00028 // Base Class Headers --
00029 //----------------------
00030 
00031 
00032 //------------------------------------
00033 // Collaborating Class Declarations --
00034 //------------------------------------
00035 
00036 
00037 //              ---------------------
00038 //              -- Class Interface --
00039 //              ---------------------
00040 
00041 class L1MuDTQualPatternLut {
00042 
00043   public:
00044 
00045     typedef std::pair< short, short > LUTID;
00046     typedef std::pair< short, std::vector<short> > LUTCONT;
00047     typedef std::map< LUTID, LUTCONT > LUT;
00048     typedef LUT::iterator EMULut_iter;
00049     
00051     L1MuDTQualPatternLut();
00052 
00054     virtual ~L1MuDTQualPatternLut();
00055 
00057     void reset();
00058     
00060     int load();
00061 
00063     void print() const;
00064 
00066     int getCoarseEta(int sp, int adr) const;
00067  
00069     const std::vector<short>& getQualifiedPatterns(int sp, int adr) const;
00070 
00072     inline int size() const { return m_lut.size(); }
00073 
00075     inline EMULut_iter begin() { return m_lut.begin(); }
00076 
00078     inline EMULut_iter end() { return m_lut.end(); }
00079     
00080   private:
00081 
00082     LUT m_lut;        // coarse eta values and list of qualified patterns
00083     
00084 };
00085 
00086 #endif