CMS 3D CMS Logo

PoolTransaction.h

Go to the documentation of this file.
00001 #ifndef CondCore_DBCommon_PoolTransaction_H
00002 #define CondCore_DBCommon_PoolTransaction_H
00003 #include "CondCore/DBCommon/interface/ITransaction.h"
00004 //
00005 // Package:     DBCommon
00006 // Class  :     PoolTransaction
00007 // 
00011 //
00012 // Author:      Zhen Xie
00013 //
00014 namespace pool{
00015   class IDataSvc;
00016 }
00017 namespace cond{
00018   class PoolConnectionProxy;
00019   class PoolTransaction : public ITransaction{
00020   public:
00021     explicit PoolTransaction(cond::PoolConnectionProxy* parentConnection);
00022     ~PoolTransaction();
00024     void start(bool readOnly);
00026     void commit();
00027     // rollback transaction
00028     void rollback();
00030     //virtual bool isActive() const;
00032     virtual bool isReadOnly() const;
00034     virtual IConnectionProxy& parentConnection();
00035     void resetPoolDataSvc(pool::IDataSvc* datasvc) const;
00037     pool::IDataSvc& poolDataSvc();
00038 
00039   private:
00040     void upgrade();
00041     void forceCommit();
00042   private:
00043     cond::PoolConnectionProxy* m_parentConnection;
00044     mutable pool::IDataSvc* m_datasvc;
00045     //mutable bool m_isReadOnly;
00046     
00047     int m_count;
00048 
00049   };
00050 }
00051 #endif

Generated on Tue Jun 9 17:26:04 2009 for CMSSW by  doxygen 1.5.4