CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DataManager.h
Go to the documentation of this file.
1 #ifndef CondTools_L1Trigger_DataManager_h
2 #define CondTools_L1Trigger_DataManager_h
3 
6 
7 #include <string>
8 
9 namespace l1t
10 {
11 
12 /* Helper class that provides common objects required to access Pool and Coral DB's.
13  * This class will initialize connections and makes sure that they are closed
14  * when it is destroyed.
15  * Connections are initialized, but user is still responsible for opening and commiting
16  * them
17  */
19 {
20  public:
21  DataManager() ;
22  explicit DataManager (const std::string & connectString,
23  const std::string & authenticationPath,
24  bool isOMDS = false );
25  virtual ~DataManager ();
26 
27  void connect(const std::string & connectString,
28  const std::string & authenticationPath,
29  bool isOMDS = false );
30  void setDebug( bool debug ) ;
31 
33  { return session ; }
34 
35  protected:
36  //Returns type object for provided type name
38 
39  // Database connection management
41 
42 private:
43  bool debugFlag = false;
44 };
45 
46 }
47 
48 #endif
type
Definition: HCALResponse.h:21
void connect(const std::string &connectString, const std::string &authenticationPath, bool isOMDS=false)
Definition: DataManager.cc:24
edm::eventsetup::TypeTag findType(const std::string &type)
Definition: DataManager.cc:45
#define debug
Definition: HDRShower.cc:19
cond::persistency::Session dbSession()
Definition: DataManager.h:32
virtual ~DataManager()
Definition: DataManager.cc:38
void setDebug(bool debug)
Definition: DataManager.cc:58
cond::persistency::Session session
Definition: DataManager.h:40