test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SummaryPlotFactory.cc
Go to the documentation of this file.
3 #include <iostream>
4 
5 using namespace sistrip;
6 
7 // -----------------------------------------------------------------------------
8 //
9 template<class T>
11  const sistrip::Presentation& pres,
12  const sistrip::View& view,
13  const std::string& level,
14  const sistrip::Granularity& gran,
15  const std::map<uint32_t,T>& data ) {
16 
17  // Some initialisation
18  SummaryPlotFactoryBase::init( mon, pres, view, level, gran );
19 
20  // Transfer appropriate monitorables info to generator object
21  if ( !SummaryPlotFactoryBase::generator_ ) { return 0; }
22  typename std::map<uint32_t,T>::const_iterator iter = data.begin();
23  for ( ; iter != data.end(); iter++ ) {
24  static float value = static_cast<float>(iter->second);
27  iter->first,
28  value );
29  }
30 
32 
33 }
34 
35 // -----------------------------------------------------------------------------
36 //
37 template<class T>
38 void SummaryPlotFactory<T>::fill( TH1& summary_histo ) {
39 
40  // Some initialisation
41  SummaryPlotFactoryBase::fill( summary_histo );
42 
43 }
44 
45 // -----------------------------------------------------------------------------
46 //
47 template class SummaryPlotFactory<uint32_t>;
48 template class SummaryPlotFactory<uint16_t>;
49 template class SummaryPlotFactory<int32_t>;
50 template class SummaryPlotFactory<int16_t>;
51 template class SummaryPlotFactory<double>;
52 template class SummaryPlotFactory<float>;
53 
void init(const sistrip::Monitorable &, const sistrip::Presentation &, const sistrip::View &, const std::string &top_level_dir, const sistrip::Granularity &)
uint32_t init(const sistrip::Monitorable &, const sistrip::Presentation &, const sistrip::View &, const std::string &top_level_dir, const sistrip::Granularity &, const std::map< uint32_t, T > &data)
uint32_t nBins() const
void fillMap(const std::string &top_level_dir, const sistrip::Granularity &, const uint32_t &key, const float &value, const float &error=0.)
void fill(TH1 &summary_histo)
sistrip::Granularity gran_
SummaryGenerator * generator_
tuple level
Definition: testEve_cfg.py:34
void fill(TH1 &summary_histo)