Sha256: e2b68dc2041d8a93c33c1960500b657cbe5bea3ab51b25a4986d62941e520d56
Contents?: true
Size: 930 Bytes
Versions: 19
Compression:
Stored size: 930 Bytes
Contents
#pragma once #include "DBAdapter.h" namespace rho { namespace db { class CDBImportTransaction { CDBAdapter& _db; String _srcZipPath; String _stateFileName; String _importDirPath; String _importZipPath; String _backupDirPath; String _backupBlobsDirPath; String _blobsListPath; enum enTxnState { txnInvalid, txnNotStarted, txnPrepareImportData, txnEnumerateOldBlobs, txnBackupOldDb, txnBackupOldBlobs, txnImportNewDb, txnImportNewBlobs, txnCleanup }; enTxnState _state; public: DEFINE_LOGCLASS; CDBImportTransaction( CDBAdapter& db, const String& zipPath = "" ); ~CDBImportTransaction() {} bool commit(); bool rollback(); bool pending(); private: void determineTxnState(); void setTxnState( enTxnState state ); bool prepareImportData(); bool enumerateOldBlobs(); bool backupOldDb(); bool backupOldBlobs(); bool importNewDb(); bool importNewBlobs(); bool cleanup(); }; } }
Version data entries
19 entries across 19 versions & 2 rubygems