CMS 3D CMS Logo

SiPixelQualityProbabilities.h
Go to the documentation of this file.
1 #ifndef CondFormats_SiPixelObjects_SiPixelQualityProbabilities_h
2 #define CondFormats_SiPixelObjects_SiPixelQualityProbabilities_h
3 
5 
6 #include <map>
7 #include <string>
8 #include <vector>
9 
11 public:
12  typedef std::vector<std::pair<std::string, float> > probabilityVec;
13  typedef std::map<unsigned int, probabilityVec> probabilityMap;
14 
18 
19  void setProbabilities(const unsigned int puBin, const probabilityVec& theProbabilities);
20 
22 
23  probabilityVec getProbabilities(const unsigned int puBin) const;
24  const probabilityVec& getProbabilities(const unsigned int puBin);
25 
26  double size() const { return m_probabilities.size(); }
27  double nelements(const int puBin) const { return m_probabilities.at(puBin).size(); }
28  std::vector<unsigned int> getPileUpBins() const;
29 
30  void printAll() const;
31 
32  //dumping values on output stream
33  void print(std::ostream& os) const;
34 
35 private:
37 
39 };
40 
41 std::ostream& operator<<(std::ostream&, SiPixelQualityProbabilities theProbabilities);
42 
43 #endif //CondFormats_SiPixelObjects_SiPixelQualityProbabilities_h
std::map< unsigned int, probabilityVec > probabilityMap
std::vector< unsigned int > getPileUpBins() const
void setProbabilities(const unsigned int puBin, const probabilityVec &theProbabilities)
std::ostream & operator<<(std::ostream &, SiPixelQualityProbabilities theProbabilities)
std::vector< std::pair< std::string, float > > probabilityVec
probabilityVec getProbabilities(const unsigned int puBin) const
double nelements(const int puBin) const
void print(std::ostream &os) const
const probabilityMap & getProbability_Map() const
#define COND_SERIALIZABLE
Definition: Serializable.h:39
SiPixelQualityProbabilities(const SiPixelQualityProbabilities &rhs)