CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
RunNumberPyWrapper.cc
Go to the documentation of this file.
1 
3 
6 
7 #include <string>
8 #include <fstream>
9 
10 using namespace runinfo_test;
11 
12 namespace cond {
13 
14  template<>
15  class ValueExtractor<RunNumber>: public BaseValueExtractor<RunNumber> {
16  public:
17 
18  typedef RunNumber Class;
20  static What what() { return What();}
21 
23  ValueExtractor(What const & what)
24  {
25  // here one can make stuff really complicated...
26  }
27  void compute(Class const & it){
28  }
29  private:
30 
31  };
32 
33 
34  template<>
37  std::stringstream ss;
38  return ss.str();
39 
40  }
41 
42  template<>
44  std::stringstream ss;
45  ss << object().m_runnumber.size() <<", ";
46  if (!object().m_runnumber.empty()) {
47  ss << object().m_runnumber.front().m_run;
48  ss << ", ";
49  ss << object().m_runnumber.front().m_name;
50  ss << ", " << object().m_runnumber.front().m_start_time_str;
51  ss << "; ";
52  ss << ", " << object().m_runnumber.front().m_stop_time_str;
53  ss << "; ";
54  for (size_t i=0; i< object().m_runnumber.front().m_subdt_joined.size(); ++i){
55  ss << ", " << object().m_runnumber.front().m_subdt_joined[i];
56  ss << "; ";
57  }
58 
59  }
60  return ss.str();
61 
62  }
63 
64 
65  template<>
67  std::string const &,
68  std::vector<int> const&,
69  std::vector<float> const& ) const {
70  std::string fname = filename + ".png";
71  std::ofstream f(fname.c_str());
72  return fname;
73  }
74 
75 
76 }
77 
int i
Definition: DBlmapReader.cc:9
#define PYTHON_WRAPPER(_class, _name)
double f[11][100]
list object
Definition: dbtoconf.py:77
string fname
main script
tuple filename
Definition: lut2db_cfg.py:20