Commit 106a2cfa authored by Andrea Valassi's avatar Andrea Valassi
Browse files

Rename COOL400 as COOL400TX for the API extensions for transactions (CORALCOOL-2943)


git-svn-id: file:///git/lcgcool.svndb/cool/trunk@20135 4525493e-7705-40b1-a816-d608a930855b
parent 893ed526
......@@ -8,7 +8,7 @@
#include "CoolKernel/FolderVersioning.h"
#include "CoolKernel/IHvsNode.h"
#include "CoolKernel/pointers.h"
#ifdef COOL400
#ifdef COOL400TX
#include "CoolKernel/ITransaction.h"
#endif
......@@ -160,7 +160,7 @@ namespace cool
/// Return the "COOL database name".
virtual const std::string& databaseName() const = 0;
#ifdef COOL400
#ifdef COOL400TX
/// Start a new transaction and enter manual transaction mode
virtual ITransactionPtr startTransaction() = 0;
#endif
......
......@@ -4,7 +4,7 @@
#include "CoolKernel/VersionInfo.h" // for #ifdef COOL4xx
// This class only exists in the COOL400 API
#ifdef COOL400
#ifdef COOL400TX
namespace cool
{
......
#ifndef COOLKERNEL_VERSIONINFO_H
#define COOLKERNEL_VERSIONINFO_H 1
// Explicitly disable COOL400 extensions (do not allow -D to enable them)
#undef COOL400 // COOL 3.x
#undef COOL400CPP11ENUM // API changes for c++11 enum class (bug #103344)
// Explicitly disable COOL4xx extensions (do not allow -D to enable them)
#undef COOL400TX // API changes to expose transactions (CORALCOOL-2707)
#undef COOL400CPP11ENUM // API changes for c++11 enum class (CORALCOOL-2233)
// This switch is no longer needed in trunk (CORALCOOL-1111, CORALCOOL-2943)
//#define COOL300 1 // COOL 3.0 or higher (COOL 2.x is no longer supported!)
......
......@@ -30,7 +30,7 @@ namespace cool
class IObjectIterator;
class IRecord;
class IRecordIterator;
#ifdef COOL400
#ifdef COOL400TX
class ITransaction;
#endif
......@@ -45,7 +45,7 @@ namespace cool
typedef std::shared_ptr<IRecord> IRecordPtr;
typedef std::vector<IRecordPtr> IRecordVector;
typedef std::shared_ptr<IRecordVector> IRecordVectorPtr;
#ifdef COOL400
#ifdef COOL400TX
typedef std::shared_ptr<ITransaction> ITransactionPtr;
#endif
......
......@@ -116,7 +116,7 @@
#include "CoolKernel/IRecordSelection.h"
#include "CoolKernel/IRecordSpecification.h"
#include "CoolKernel/ITime.h"
#ifdef COOL400
#ifdef COOL400TX
#include "CoolKernel/ITransaction.h"
#endif
#include "CoolKernel/PayloadMode.h"
......@@ -180,7 +180,7 @@ namespace dummy
cool::IRecordVector aIRecordVector;
cool::IRecordVector::iterator aIRecordVectorIterator;
cool::IRecordVectorPtr aIRecordVectorPtr;
#ifdef COOL400
#ifdef COOL400TX
cool::ITransactionPtr aITransactionPtr;
#endif
cool::Record aRecord;
......
#include "CoolKernel/VersionInfo.h" // for #ifdef COOL4xx
#ifdef COOL400
#ifdef COOL400TX
// Include files
#include <string>
......
......@@ -4,7 +4,7 @@
#include "CoolKernel/VersionInfo.h" // for #ifdef COOL4xx
// This class only exists in the COOL400 API
#ifdef COOL400
#ifdef COOL400TX
// Include files
#include <boost/shared_ptr.hpp>
......
......@@ -1842,7 +1842,7 @@ void RalDatabase::disconnect()
//-----------------------------------------------------------------------------
#ifdef COOL400
#ifdef COOL400TX
ITransactionPtr RalDatabase::startTransaction()
{
transactionMgr()->setAutoTransactions( false );
......
......@@ -176,7 +176,7 @@ namespace cool
/// Delegated to RalSessionMgr.
void disconnect();
#ifdef COOL400
#ifdef COOL400TX
/// Start a new transaction and enter manual transaction mode
virtual ITransactionPtr startTransaction();
#endif
......
......@@ -10,7 +10,7 @@
#include "CoolKernel/ChannelSelection.h"
#include "CoolKernel/PayloadMode.h"
#include "CoolKernel/IDatabase.h"
#ifdef COOL400
#ifdef COOL400TX
#include "CoolKernel/ITransaction.h"
#endif
#include "CoolKernel/Record.h"
......@@ -222,7 +222,7 @@ namespace cool
/// Return the "COOL database name".
const std::string& databaseName() const;
#ifdef COOL400
#ifdef COOL400TX
/// Start a new transaction and enter manual transaction mode
virtual ITransactionPtr startTransaction() = 0;
#endif
......
......@@ -166,7 +166,7 @@ namespace cool
return db().databaseName();
}
#ifdef COOL400
#ifdef COOL400TX
/// Start a new transaction and enter manual transaction mode
virtual ITransactionPtr startTransaction();
#endif
......
......@@ -134,7 +134,7 @@ private:
CPPUNIT_TEST( test_closeDatabase_exceptional_database_behavior );
CPPUNIT_TEST( test_nodeTable_lastModDate );
CPPUNIT_TEST( test_openDatabase_ro_updateExceptionBug30500 );
#ifdef COOL400
#ifdef COOL400TX
CPPUNIT_TEST( test_manualTransaction_commit );
CPPUNIT_TEST( test_manualTransaction_rollback );
CPPUNIT_TEST( test_manualTransaction_tag_rollback );
......@@ -345,7 +345,7 @@ public:
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#ifdef COOL400
#ifdef COOL400TX
// Tests manual transaction commit
void test_manualTransaction_commit()
{
......
......@@ -206,7 +206,7 @@ private:
CPPUNIT_TEST( test_cloneHeadTag );
CPPUNIT_TEST( test_cloneHeadTag_sepPayload );
CPPUNIT_TEST( test_cloneHeadTag_vector );
#ifdef COOL400
#ifdef COOL400TX
CPPUNIT_TEST( test_manualTransaction_renamePayload );
CPPUNIT_TEST( test_manualTransaction_extendPayloadSpecification );
#endif
......@@ -286,7 +286,7 @@ public:
(ChannelId)8, obj->channelId() );
}
#ifdef COOL400
#ifdef COOL400TX
/// Tests renamePayload behavior in manual transaction mode
void test_manualTransaction_renamePayload()
{
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment