test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HcalDbOnline.h
Go to the documentation of this file.
1 //
2 // F.Ratnikov (UMd), Jan. 6, 2006
3 //
4 #ifndef HcalDbOnline_h
5 #define HcalDbOnline_h
6 
7 #include <memory>
8 
17 
26 namespace oracle {
27  namespace occi {
28  class Environment;
29  class Connection;
30  class Statement;
31  }
32 }
33 
34 class HcalDbOnline {
35  public:
36  typedef unsigned long long IOVTime;
37  typedef std::pair <IOVTime, IOVTime> IntervalOV;
38 
39  HcalDbOnline (const std::string& fDb, bool fVerbose = false);
40  ~HcalDbOnline ();
41 
42  bool getObject (HcalPedestals* fObject, HcalPedestalWidths* fWidths, const std::string& fTag, IOVTime fTime);
43  bool getObject (HcalPedestals* fObject, const std::string& fTag, IOVTime fTime);
44  bool getObject (HcalGains* fObject, HcalGainWidths* fWidths, const std::string& fTag, IOVTime fTime);
45  bool getObject (HcalGains* fObject, const std::string& fTag, IOVTime fTime);
46  bool getObject (HcalPedestalWidths* fObject, const std::string& fTag, IOVTime fTime);
47  bool getObject (HcalGainWidths* fObject, const std::string& fTag, IOVTime fTime);
48  bool getObject (HcalElectronicsMap* fObject, const std::string& fTag, IOVTime fTime);
49  bool getObject (HcalQIEData* fObject, const std::string& fTag, IOVTime fTime);
50  bool getObject (HcalCalibrationQIEData* fObject, const std::string& fTag, IOVTime fTime);
51 
52  std::vector<std::string> metadataAllTags ();
53  std::vector<IntervalOV> getIOVs (const std::string& fTag);
54 
55 
56  private:
57  oracle::occi::Environment* mEnvironment;
58  oracle::occi::Connection* mConnect;
59  oracle::occi::Statement* mStatement;
60  template <class T> bool getObjectGeneric (T* fObject, const std::string& fTag);
61  bool mVerbose;
62 };
63 #endif
oracle::occi::Environment * mEnvironment
Definition: HcalDbOnline.h:57
std::vector< IntervalOV > getIOVs(const std::string &fTag)
unsigned long long IOVTime
Definition: HcalDbOnline.h:36
std::pair< IOVTime, IOVTime > IntervalOV
Definition: HcalDbOnline.h:37
Gather conditions data from online DB.
Definition: HcalDbOnline.h:34
HcalDbOnline(const std::string &fDb, bool fVerbose=false)
Definition: HcalDbOnline.cc:26
oracle::occi::Statement * mStatement
Definition: HcalDbOnline.h:59
std::vector< std::string > metadataAllTags()
bool getObject(HcalPedestals *fObject, HcalPedestalWidths *fWidths, const std::string &fTag, IOVTime fTime)
oracle::occi::Connection * mConnect
Definition: HcalDbOnline.h:58
long double T
bool getObjectGeneric(T *fObject, const std::string &fTag)