test
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 
8 
9 #include <string>
10 
11 namespace l1t
12 {
13 
14 /* Helper class that provides common objects required to access Pool and Coral DB's.
15  * This class will initialize connections and makes sure that they are closed
16  * when it is destroyed.
17  * Connections are initialized, but user is still responsible for opening and commiting
18  * them
19  */
21 {
22  public:
23  DataManager() ;
24  explicit DataManager (const std::string & connectString,
25  const std::string & authenticationPath,
26  bool isOMDS = false );
27  virtual ~DataManager ();
28 
29  void connect(const std::string & connectString,
30  const std::string & authenticationPath,
31  bool isOMDS = false );
32  void setDebug( bool debug ) ;
33 
35  { return session ; }
36 
38  { return connection ; }
39  protected:
40  //Returns type object for provided type name
42 
43  // Database connection management
46 };
47 
48 }
49 
50 #endif
type
Definition: HCALResponse.h:21
edm::eventsetup::TypeTag findType(const std::string &type) const
Definition: DataManager.cc:57
void connect(const std::string &connectString, const std::string &authenticationPath, bool isOMDS=false)
Definition: DataManager.cc:24
cond::DbSession * dbSession()
Definition: DataManager.h:34
#define debug
Definition: HDRShower.cc:19
cond::DbConnection * dbConnection()
Definition: DataManager.h:37
virtual ~DataManager()
Definition: DataManager.cc:45
cond::DbConnection * connection
Definition: DataManager.h:45
void setDebug(bool debug)
Definition: DataManager.cc:70
cond::DbSession * session
Definition: DataManager.h:44