CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_2_7_hltpatch2/src/CondCore/DBCommon/plugins/SQLiteProxy.cc

Go to the documentation of this file.
00001 #include "CondCore/DBCommon/interface/FipProtocolParser.h"
00002 #include "CondCore/DBCommon/interface/TechnologyProxy.h"
00003 #include <string>
00004 namespace cond{
00005   class SQLiteProxy:public TechnologyProxy{
00006   public:
00007     SQLiteProxy(){}
00008     ~SQLiteProxy(){}
00009     void initialize( const DbConnection& ){
00010     }
00011     std::string 
00012     getRealConnectString( const std::string &userconnect ) const{
00013       if( userconnect.find("sqlite_fip:") != std::string::npos ){
00014         cond::FipProtocolParser p;
00015         return p.getRealConnect( userconnect );
00016       }
00017       return userconnect;
00018     }
00019 
00020     std::string 
00021     getRealConnectString( const std::string &userconnect, const std::string& ) const {
00022       return getRealConnectString( userconnect );
00023     }
00024 
00025     bool isTransactional() const { return true;}
00026 
00027   };  
00028 }//ns cond
00029 
00030 #include "CondCore/DBCommon/interface/TechnologyProxyFactory.h"
00031 DEFINE_EDM_PLUGIN(cond::TechnologyProxyFactory,cond::SQLiteProxy,"sqlite");
00032