Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:24:51

0001 #ifndef _HFVALUESTRUCT_H
0002 #define _HFVALUESTRUCT_H
0003 
0004 #include <vector>
0005 
0006 namespace reco {
0007 
0008   class HFValueStruct {
0009   public:
0010     HFValueStruct() {}
0011     HFValueStruct(const int& version, const std::vector<double>& vect);
0012     // returns single value by index
0013 
0014     double EnCor(int ieta) const;
0015     double PUSlope(int ieta) const;
0016     double PUIntercept(int ieta) const;
0017 
0018     // sets single value by index
0019     void setEnCor(int ieta, double val);
0020     void setPUSlope(int ieta, double val);
0021     void setPUIntercept(int ieta, double val);
0022 
0023     // returns whole vector
0024     std::vector<double> EnCor() const;
0025     std::vector<double> PUSlope() const;
0026     std::vector<double> PUIntercept() const;
0027 
0028     // set whole vector
0029     void setEnCor(const std::vector<double>& val);
0030     void setPUSlope(const std::vector<double>& val);
0031     void setPUIntercept(const std::vector<double>& val);
0032 
0033   private:
0034     int v_;
0035     std::vector<double> hfvv_;
0036     //std::vector<double> SetHfvvFromDB_();  //will need when in database
0037     bool doEnCor_, doPU_;
0038 
0039     int indexByIeta(int& ieta) const;
0040     int ietaByIndex(int& indx) const;
0041   };
0042 }  // namespace reco
0043 #endif