\2013-02-20 Mark Lam <mark.lam@apple.com>
authormark.lam@apple.com <mark.lam@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 21 Feb 2013 02:36:26 +0000 (02:36 +0000)
committermark.lam@apple.com <mark.lam@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 21 Feb 2013 02:36:26 +0000 (02:36 +0000)
Rename DatabaseBackendAsync to DatabaseBackend.
https://bugs.webkit.org/show_bug.cgi?id=110422.

Reviewed by Geoffrey Garen.

This is a purely cosmetic change to make the naming consistent with
the front-end Database.

No new tests.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Modules/webdatabase/ChangeVersionWrapper.cpp:
(WebCore::ChangeVersionWrapper::performPreflight):
(WebCore::ChangeVersionWrapper::performPostflight):
* Modules/webdatabase/Database.cpp:
(WebCore::Database::Database):
(WebCore::Database::from):
(WebCore::Database::backend):
* Modules/webdatabase/Database.h:
* Modules/webdatabase/DatabaseBackend.cpp: Copied from Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.cpp.
(WebCore::DatabaseBackend::DatabaseBackend):
(WebCore::DatabaseBackend::openAndVerifyVersion):
(WebCore::DatabaseBackend::performOpenAndVerify):
(WebCore::DatabaseBackend::close):
(WebCore::DatabaseBackend::runTransaction):
(WebCore::DatabaseBackend::inProgressTransactionCompleted):
(WebCore::DatabaseBackend::scheduleTransaction):
(WebCore::DatabaseBackend::scheduleTransactionStep):
(WebCore::DatabaseBackend::transactionClient):
(WebCore::DatabaseBackend::transactionCoordinator):
* Modules/webdatabase/DatabaseBackend.h: Copied from Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.h.
* Modules/webdatabase/DatabaseBackendAsync.cpp: Removed.
* Modules/webdatabase/DatabaseBackendAsync.h: Removed.
* Modules/webdatabase/DatabaseBackendBase.cpp:
(WebCore::DatabaseBackendBase::~DatabaseBackendBase):
* Modules/webdatabase/DatabaseManager.cpp:
* Modules/webdatabase/DatabaseServer.cpp:
* Modules/webdatabase/DatabaseTask.cpp:
(WebCore::DatabaseTask::DatabaseTask):
(WebCore::DatabaseBackend::DatabaseOpenTask::DatabaseOpenTask):
(WebCore::DatabaseBackend::DatabaseOpenTask::doPerformTask):
(WebCore::DatabaseBackend::DatabaseOpenTask::debugTaskName):
(WebCore::DatabaseBackend::DatabaseCloseTask::DatabaseCloseTask):
(WebCore::DatabaseBackend::DatabaseCloseTask::doPerformTask):
(WebCore::DatabaseBackend::DatabaseCloseTask::debugTaskName):
(WebCore::DatabaseBackend::DatabaseTransactionTask::DatabaseTransactionTask):
(WebCore::DatabaseBackend::DatabaseTransactionTask::~DatabaseTransactionTask):
(WebCore::DatabaseBackend::DatabaseTransactionTask::doPerformTask):
(WebCore::DatabaseBackend::DatabaseTransactionTask::debugTaskName):
(WebCore::DatabaseBackend::DatabaseTableNamesTask::DatabaseTableNamesTask):
(WebCore::DatabaseBackend::DatabaseTableNamesTask::doPerformTask):
(WebCore::DatabaseBackend::DatabaseTableNamesTask::debugTaskName):
* Modules/webdatabase/DatabaseTask.h:
(WebCore::DatabaseTask::database):
(DatabaseTask):
(WebCore::DatabaseBackend::DatabaseOpenTask::create):
(DatabaseBackend::DatabaseOpenTask):
(WebCore::DatabaseBackend::DatabaseCloseTask::create):
(DatabaseBackend::DatabaseCloseTask):
(WebCore::DatabaseBackend::DatabaseTableNamesTask::create):
(DatabaseBackend::DatabaseTableNamesTask):
* Modules/webdatabase/DatabaseThread.cpp:
(WebCore::DatabaseThread::recordDatabaseOpen):
(WebCore::DatabaseThread::recordDatabaseClosed):
(WebCore::SameDatabasePredicate::SameDatabasePredicate):
(SameDatabasePredicate):
(WebCore::DatabaseThread::unscheduleDatabaseTasks):
* Modules/webdatabase/DatabaseThread.h:
* Modules/webdatabase/SQLStatementBackend.cpp:
(WebCore::SQLStatementBackend::execute):
(WebCore::SQLStatementBackend::setDatabaseDeletedError):
(WebCore::SQLStatementBackend::setVersionMismatchedError):
(WebCore::SQLStatementBackend::setFailureDueToQuota):
* Modules/webdatabase/SQLStatementBackend.h:
* Modules/webdatabase/SQLTransactionBackend.cpp:
(WebCore::SQLTransactionBackend::create):
(WebCore::SQLTransactionBackend::SQLTransactionBackend):
* Modules/webdatabase/SQLTransactionBackend.h:
(WebCore::SQLTransactionBackend::database):
* Modules/webdatabase/SQLTransactionCoordinator.cpp:
(WebCore::getDatabaseIdentifier):
* Target.pri:
* WebCore.gypi:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@143551 268f45cc-cd09-0410-ab3c-d52691b4dbfc

26 files changed:
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/GNUmakefile.list.am
Source/WebCore/Modules/webdatabase/ChangeVersionWrapper.cpp
Source/WebCore/Modules/webdatabase/Database.cpp
Source/WebCore/Modules/webdatabase/Database.h
Source/WebCore/Modules/webdatabase/DatabaseBackend.cpp [moved from Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.cpp with 85% similarity]
Source/WebCore/Modules/webdatabase/DatabaseBackend.h [moved from Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.h with 86% similarity]
Source/WebCore/Modules/webdatabase/DatabaseBackendBase.cpp
Source/WebCore/Modules/webdatabase/DatabaseManager.cpp
Source/WebCore/Modules/webdatabase/DatabaseServer.cpp
Source/WebCore/Modules/webdatabase/DatabaseTask.cpp
Source/WebCore/Modules/webdatabase/DatabaseTask.h
Source/WebCore/Modules/webdatabase/DatabaseThread.cpp
Source/WebCore/Modules/webdatabase/DatabaseThread.h
Source/WebCore/Modules/webdatabase/SQLStatementBackend.cpp
Source/WebCore/Modules/webdatabase/SQLStatementBackend.h
Source/WebCore/Modules/webdatabase/SQLTransactionBackend.cpp
Source/WebCore/Modules/webdatabase/SQLTransactionBackend.h
Source/WebCore/Modules/webdatabase/SQLTransactionCoordinator.cpp
Source/WebCore/Target.pri
Source/WebCore/WebCore.gypi
Source/WebCore/WebCore.vcproj/WebCore.vcproj
Source/WebCore/WebCore.vcxproj/WebCore.vcxproj
Source/WebCore/WebCore.vcxproj/WebCore.vcxproj.filters
Source/WebCore/WebCore.xcodeproj/project.pbxproj

index 018dd10..3f89a0e 100644 (file)
@@ -939,7 +939,7 @@ set(WebCore_SOURCES
     Modules/webdatabase/DOMWindowWebDatabase.cpp
     Modules/webdatabase/Database.cpp
     Modules/webdatabase/DatabaseAuthorizer.cpp
-    Modules/webdatabase/DatabaseBackendAsync.cpp
+    Modules/webdatabase/DatabaseBackend.cpp
     Modules/webdatabase/DatabaseBackendBase.cpp
     Modules/webdatabase/DatabaseBackendContext.cpp
     Modules/webdatabase/DatabaseBackendSync.cpp
index c7e37ba..fb8144f 100644 (file)
@@ -1,3 +1,94 @@
+\2013-02-20  Mark Lam  <mark.lam@apple.com>
+
+        Rename DatabaseBackendAsync to DatabaseBackend.
+        https://bugs.webkit.org/show_bug.cgi?id=110422.
+
+        Reviewed by Geoffrey Garen.
+
+        This is a purely cosmetic change to make the naming consistent with
+        the front-end Database.
+
+        No new tests.
+
+        * CMakeLists.txt:
+        * GNUmakefile.list.am:
+        * Modules/webdatabase/ChangeVersionWrapper.cpp:
+        (WebCore::ChangeVersionWrapper::performPreflight):
+        (WebCore::ChangeVersionWrapper::performPostflight):
+        * Modules/webdatabase/Database.cpp:
+        (WebCore::Database::Database):
+        (WebCore::Database::from):
+        (WebCore::Database::backend):
+        * Modules/webdatabase/Database.h:
+        * Modules/webdatabase/DatabaseBackend.cpp: Copied from Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.cpp.
+        (WebCore::DatabaseBackend::DatabaseBackend):
+        (WebCore::DatabaseBackend::openAndVerifyVersion):
+        (WebCore::DatabaseBackend::performOpenAndVerify):
+        (WebCore::DatabaseBackend::close):
+        (WebCore::DatabaseBackend::runTransaction):
+        (WebCore::DatabaseBackend::inProgressTransactionCompleted):
+        (WebCore::DatabaseBackend::scheduleTransaction):
+        (WebCore::DatabaseBackend::scheduleTransactionStep):
+        (WebCore::DatabaseBackend::transactionClient):
+        (WebCore::DatabaseBackend::transactionCoordinator):
+        * Modules/webdatabase/DatabaseBackend.h: Copied from Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.h.
+        * Modules/webdatabase/DatabaseBackendAsync.cpp: Removed.
+        * Modules/webdatabase/DatabaseBackendAsync.h: Removed.
+        * Modules/webdatabase/DatabaseBackendBase.cpp:
+        (WebCore::DatabaseBackendBase::~DatabaseBackendBase):
+        * Modules/webdatabase/DatabaseManager.cpp:
+        * Modules/webdatabase/DatabaseServer.cpp:
+        * Modules/webdatabase/DatabaseTask.cpp:
+        (WebCore::DatabaseTask::DatabaseTask):
+        (WebCore::DatabaseBackend::DatabaseOpenTask::DatabaseOpenTask):
+        (WebCore::DatabaseBackend::DatabaseOpenTask::doPerformTask):
+        (WebCore::DatabaseBackend::DatabaseOpenTask::debugTaskName):
+        (WebCore::DatabaseBackend::DatabaseCloseTask::DatabaseCloseTask):
+        (WebCore::DatabaseBackend::DatabaseCloseTask::doPerformTask):
+        (WebCore::DatabaseBackend::DatabaseCloseTask::debugTaskName):
+        (WebCore::DatabaseBackend::DatabaseTransactionTask::DatabaseTransactionTask):
+        (WebCore::DatabaseBackend::DatabaseTransactionTask::~DatabaseTransactionTask):
+        (WebCore::DatabaseBackend::DatabaseTransactionTask::doPerformTask):
+        (WebCore::DatabaseBackend::DatabaseTransactionTask::debugTaskName):
+        (WebCore::DatabaseBackend::DatabaseTableNamesTask::DatabaseTableNamesTask):
+        (WebCore::DatabaseBackend::DatabaseTableNamesTask::doPerformTask):
+        (WebCore::DatabaseBackend::DatabaseTableNamesTask::debugTaskName):
+        * Modules/webdatabase/DatabaseTask.h:
+        (WebCore::DatabaseTask::database):
+        (DatabaseTask):
+        (WebCore::DatabaseBackend::DatabaseOpenTask::create):
+        (DatabaseBackend::DatabaseOpenTask):
+        (WebCore::DatabaseBackend::DatabaseCloseTask::create):
+        (DatabaseBackend::DatabaseCloseTask):
+        (WebCore::DatabaseBackend::DatabaseTableNamesTask::create):
+        (DatabaseBackend::DatabaseTableNamesTask):
+        * Modules/webdatabase/DatabaseThread.cpp:
+        (WebCore::DatabaseThread::recordDatabaseOpen):
+        (WebCore::DatabaseThread::recordDatabaseClosed):
+        (WebCore::SameDatabasePredicate::SameDatabasePredicate):
+        (SameDatabasePredicate):
+        (WebCore::DatabaseThread::unscheduleDatabaseTasks):
+        * Modules/webdatabase/DatabaseThread.h:
+        * Modules/webdatabase/SQLStatementBackend.cpp:
+        (WebCore::SQLStatementBackend::execute):
+        (WebCore::SQLStatementBackend::setDatabaseDeletedError):
+        (WebCore::SQLStatementBackend::setVersionMismatchedError):
+        (WebCore::SQLStatementBackend::setFailureDueToQuota):
+        * Modules/webdatabase/SQLStatementBackend.h:
+        * Modules/webdatabase/SQLTransactionBackend.cpp:
+        (WebCore::SQLTransactionBackend::create):
+        (WebCore::SQLTransactionBackend::SQLTransactionBackend):
+        * Modules/webdatabase/SQLTransactionBackend.h:
+        (WebCore::SQLTransactionBackend::database):
+        * Modules/webdatabase/SQLTransactionCoordinator.cpp:
+        (WebCore::getDatabaseIdentifier):
+        * Target.pri:
+        * WebCore.gypi:
+        * WebCore.vcproj/WebCore.vcproj:
+        * WebCore.vcxproj/WebCore.vcxproj:
+        * WebCore.vcxproj/WebCore.vcxproj.filters:
+        * WebCore.xcodeproj/project.pbxproj:
+
 2013-02-20  David Kilzer  <ddkilzer@apple.com>
 
         Upstream SharedTimerIOS.mm
index 72f8880..61f41bc 100644 (file)
@@ -2111,8 +2111,8 @@ webcore_modules_sources += \
        Source/WebCore/Modules/webdatabase/Database.h \
        Source/WebCore/Modules/webdatabase/DatabaseAuthorizer.cpp \
        Source/WebCore/Modules/webdatabase/DatabaseAuthorizer.h \
-       Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.cpp \
-       Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.h \
+       Source/WebCore/Modules/webdatabase/DatabaseBackend.cpp \
+       Source/WebCore/Modules/webdatabase/DatabaseBackend.h \
        Source/WebCore/Modules/webdatabase/DatabaseBackendBase.cpp \
        Source/WebCore/Modules/webdatabase/DatabaseBackendBase.h \
        Source/WebCore/Modules/webdatabase/DatabaseBackendContext.cpp \
index 4e77c3b..3bf4c65 100644 (file)
@@ -47,7 +47,7 @@ bool ChangeVersionWrapper::performPreflight(SQLTransactionBackend* transaction)
 {
     ASSERT(transaction && transaction->database());
 
-    DatabaseBackendAsync* database = transaction->database();
+    DatabaseBackend* database = transaction->database();
 
     String actualVersion;
     if (!database->getVersionFromDatabase(actualVersion)) {
@@ -71,7 +71,7 @@ bool ChangeVersionWrapper::performPostflight(SQLTransactionBackend* transaction)
 {
     ASSERT(transaction && transaction->database());
 
-    DatabaseBackendAsync* database = transaction->database();
+    DatabaseBackend* database = transaction->database();
 
     if (!database->setVersionInDatabase(m_newVersion)) {
         int sqliteError = database->sqliteDatabase().lastError();
index 4e321d7..c6dc963 100644 (file)
@@ -77,8 +77,8 @@ PassRefPtr<Database> Database::create(ScriptExecutionContext*, PassRefPtr<Databa
 Database::Database(PassRefPtr<DatabaseBackendContext> databaseContext,
     const String& name, const String& expectedVersion, const String& displayName, unsigned long estimatedSize)
     : DatabaseBase(databaseContext->scriptExecutionContext())
-    , DatabaseBackendAsync(databaseContext, name, expectedVersion, displayName, estimatedSize)
-    , m_databaseContext(DatabaseBackendAsync::databaseContext()->frontend())
+    , DatabaseBackend(databaseContext, name, expectedVersion, displayName, estimatedSize)
+    , m_databaseContext(DatabaseBackend::databaseContext()->frontend())
     , m_deleted(false)
 {
     m_databaseThreadSecurityOrigin = m_contextThreadSecurityOrigin->isolatedCopy();
@@ -123,12 +123,12 @@ Database::~Database()
     }
 }
 
-Database* Database::from(DatabaseBackendAsync* backend)
+Database* Database::from(DatabaseBackend* backend)
 {
     return static_cast<Database*>(backend->m_frontend);
 }
 
-PassRefPtr<DatabaseBackendAsync> Database::backend()
+PassRefPtr<DatabaseBackend> Database::backend()
 {
     return this;
 }
index 9d71271..d1fff08 100644 (file)
@@ -31,7 +31,7 @@
 
 #if ENABLE(SQL_DATABASE)
 
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 #include "DatabaseBase.h"
 #include "DatabaseBasicTypes.h"
 #include "DatabaseError.h"
@@ -49,7 +49,7 @@ class SQLTransactionCallback;
 class SQLTransactionErrorCallback;
 class VoidCallback;
 
-class Database : public DatabaseBase, public DatabaseBackendAsync {
+class Database : public DatabaseBase, public DatabaseBackend {
 public:
     virtual ~Database();
 
@@ -61,7 +61,7 @@ public:
     void readTransaction(PassRefPtr<SQLTransactionCallback>, PassRefPtr<SQLTransactionErrorCallback>, PassRefPtr<VoidCallback> successCallback);
 
     // Internal engine support
-    static Database* from(DatabaseBackendAsync*);
+    static Database* from(DatabaseBackend*);
     DatabaseContext* databaseContext() const { return m_databaseContext.get(); }
 
     Vector<String> tableNames();
@@ -81,7 +81,7 @@ public:
 private:
     Database(PassRefPtr<DatabaseBackendContext>, const String& name,
         const String& expectedVersion, const String& displayName, unsigned long estimatedSize);
-    PassRefPtr<DatabaseBackendAsync> backend();
+    PassRefPtr<DatabaseBackend> backend();
     static PassRefPtr<Database> create(ScriptExecutionContext*, PassRefPtr<DatabaseBackendBase>);
 
     void runTransaction(PassRefPtr<SQLTransactionCallback>, PassRefPtr<SQLTransactionErrorCallback>,
@@ -104,7 +104,7 @@ private:
 
     friend class DatabaseManager;
     friend class DatabaseServer; // FIXME: remove this when the backend has been split out.
-    friend class DatabaseBackendAsync; // FIXME: remove this when the backend has been split out.
+    friend class DatabaseBackend; // FIXME: remove this when the backend has been split out.
     friend class SQLStatement;
     friend class SQLTransaction;
 };
@@ -24,7 +24,7 @@
  */
 
 #include "config.h"
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 
 #if ENABLE(SQL_DATABASE)
 
 
 namespace WebCore {
 
-DatabaseBackendAsync::DatabaseBackendAsync(PassRefPtr<DatabaseBackendContext> databaseContext, const String& name, const String& expectedVersion, const String& displayName, unsigned long estimatedSize)
+DatabaseBackend::DatabaseBackend(PassRefPtr<DatabaseBackendContext> databaseContext, const String& name, const String& expectedVersion, const String& displayName, unsigned long estimatedSize)
     : DatabaseBackendBase(databaseContext, name, expectedVersion, displayName, estimatedSize, DatabaseType::Async)
     , m_transactionInProgress(false)
     , m_isTransactionQueueEnabled(true)
 {
 }
 
-bool DatabaseBackendAsync::openAndVerifyVersion(bool setVersionInNewDatabase, DatabaseError& error, String& errorMessage)
+bool DatabaseBackend::openAndVerifyVersion(bool setVersionInNewDatabase, DatabaseError& error, String& errorMessage)
 {
     DatabaseTaskSynchronizer synchronizer;
     if (!databaseContext()->databaseThread() || databaseContext()->databaseThread()->terminationRequested(&synchronizer))
@@ -66,7 +66,7 @@ bool DatabaseBackendAsync::openAndVerifyVersion(bool setVersionInNewDatabase, Da
     return success;
 }
 
-bool DatabaseBackendAsync::performOpenAndVerify(bool setVersionInNewDatabase, DatabaseError& error, String& errorMessage)
+bool DatabaseBackend::performOpenAndVerify(bool setVersionInNewDatabase, DatabaseError& error, String& errorMessage)
 {
     if (DatabaseBackendBase::performOpenAndVerify(setVersionInNewDatabase, error, errorMessage)) {
         if (databaseContext()->databaseThread())
@@ -78,7 +78,7 @@ bool DatabaseBackendAsync::performOpenAndVerify(bool setVersionInNewDatabase, Da
     return false;
 }
 
-void DatabaseBackendAsync::close()
+void DatabaseBackend::close()
 {
     ASSERT(databaseContext()->databaseThread());
     ASSERT(currentThread() == databaseContext()->databaseThread()->getThreadID());
@@ -107,12 +107,12 @@ void DatabaseBackendAsync::close()
     // to it with a local pointer here for a liitle longer, so that we can
     // unschedule any DatabaseTasks that refer to it before the database gets
     // deleted.
-    RefPtr<DatabaseBackendAsync> protect = this;
+    RefPtr<DatabaseBackend> protect = this;
     databaseContext()->databaseThread()->recordDatabaseClosed(this);
     databaseContext()->databaseThread()->unscheduleDatabaseTasks(this);
 }
 
-PassRefPtr<SQLTransactionBackend> DatabaseBackendAsync::runTransaction(PassRefPtr<SQLTransaction> transaction,
+PassRefPtr<SQLTransactionBackend> DatabaseBackend::runTransaction(PassRefPtr<SQLTransaction> transaction,
     bool readOnly, const ChangeVersionData* data)
 {
     MutexLocker locker(m_transactionInProgressMutex);
@@ -131,14 +131,14 @@ PassRefPtr<SQLTransactionBackend> DatabaseBackendAsync::runTransaction(PassRefPt
     return transactionBackend;
 }
 
-void DatabaseBackendAsync::inProgressTransactionCompleted()
+void DatabaseBackend::inProgressTransactionCompleted()
 {
     MutexLocker locker(m_transactionInProgressMutex);
     m_transactionInProgress = false;
     scheduleTransaction();
 }
 
-void DatabaseBackendAsync::scheduleTransaction()
+void DatabaseBackend::scheduleTransaction()
 {
     ASSERT(!m_transactionInProgressMutex.tryLock()); // Locked by caller.
     RefPtr<SQLTransactionBackend> transaction;
@@ -155,7 +155,7 @@ void DatabaseBackendAsync::scheduleTransaction()
         m_transactionInProgress = false;
 }
 
-void DatabaseBackendAsync::scheduleTransactionStep(SQLTransactionBackend* transaction)
+void DatabaseBackend::scheduleTransactionStep(SQLTransactionBackend* transaction)
 {
     if (!databaseContext()->databaseThread())
         return;
@@ -165,12 +165,12 @@ void DatabaseBackendAsync::scheduleTransactionStep(SQLTransactionBackend* transa
     databaseContext()->databaseThread()->scheduleTask(task.release());
 }
 
-SQLTransactionClient* DatabaseBackendAsync::transactionClient() const
+SQLTransactionClient* DatabaseBackend::transactionClient() const
 {
     return databaseContext()->databaseThread()->transactionClient();
 }
 
-SQLTransactionCoordinator* DatabaseBackendAsync::transactionCoordinator() const
+SQLTransactionCoordinator* DatabaseBackend::transactionCoordinator() const
 {
     return databaseContext()->databaseThread()->transactionCoordinator();
 }
@@ -23,8 +23,8 @@
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 
  */
 
-#ifndef DatabaseBackendAsync_h
-#define DatabaseBackendAsync_h
+#ifndef DatabaseBackend_h
+#define DatabaseBackend_h
 
 #if ENABLE(SQL_DATABASE)
 
@@ -42,15 +42,15 @@ class SQLTransactionBackend;
 class SQLTransactionClient;
 class SQLTransactionCoordinator;
 
-// FIXME: This implementation of DatabaseBackendAsync is only a place holder
+// FIXME: This implementation of DatabaseBackend is only a place holder
 // for the split out of the Database backend to be done later. This
 // place holder is needed to allow other code that need to reference the
-// DatabaseBackendAsync to do so before the proper backend split is
+// DatabaseBackend to do so before the proper backend split is
 // available. This should be replaced with the actual implementation later.
 
-class DatabaseBackendAsync : public DatabaseBackendBase {
+class DatabaseBackend : public DatabaseBackendBase {
 public:
-    DatabaseBackendAsync(PassRefPtr<DatabaseBackendContext>, const String& name, const String& expectedVersion, const String& displayName, unsigned long estimatedSize);
+    DatabaseBackend(PassRefPtr<DatabaseBackendContext>, const String& name, const String& expectedVersion, const String& displayName, unsigned long estimatedSize);
 
     virtual bool openAndVerifyVersion(bool setVersionInNewDatabase, DatabaseError&, String& errorMessage);
     void close();
@@ -84,4 +84,4 @@ private:
 
 #endif // ENABLE(SQL_DATABASE)
 
-#endif // DatabaseBackendAsync_h
+#endif // DatabaseBackend_h
index 8a5fff6..19b8662 100644 (file)
@@ -244,7 +244,7 @@ DatabaseBackendBase::~DatabaseBackendBase()
     // SQLite is "multi-thread safe", but each database handle can only be used
     // on a single thread at a time.
     //
-    // For DatabaseBackendAsync, we open the SQLite database on the DatabaseThread,
+    // For DatabaseBackend, we open the SQLite database on the DatabaseThread,
     // and hence we should also close it on that same thread. This means that the
     // SQLite database need to be closed by another mechanism (see
     // DatabaseContext::stopDatabases()). By the time we get here, the SQLite
index 3c3ce0d..4403a90 100644 (file)
@@ -30,7 +30,7 @@
 
 #include "AbstractDatabaseServer.h"
 #include "Database.h"
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 #include "DatabaseBackendBase.h"
 #include "DatabaseBackendContext.h"
 #include "DatabaseBackendSync.h"
index ede541e..371321e 100644 (file)
@@ -29,7 +29,7 @@
 #if ENABLE(SQL_DATABASE)
 
 #include "Database.h"
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 #include "DatabaseBackendContext.h"
 #include "DatabaseBackendSync.h"
 #include "DatabaseSync.h"
index e95e4ad..7b79468 100644 (file)
@@ -31,7 +31,7 @@
 #if ENABLE(SQL_DATABASE)
 
 #include "Database.h"
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 #include "Logging.h"
 
 namespace WebCore {
@@ -60,7 +60,7 @@ void DatabaseTaskSynchronizer::taskCompleted()
     m_synchronousMutex.unlock();
 }
 
-DatabaseTask::DatabaseTask(DatabaseBackendAsync* database, DatabaseTaskSynchronizer* synchronizer)
+DatabaseTask::DatabaseTask(DatabaseBackend* database, DatabaseTaskSynchronizer* synchronizer)
     : m_database(database)
     , m_synchronizer(synchronizer)
 #if !LOG_DISABLED
@@ -99,7 +99,7 @@ void DatabaseTask::performTask()
 // *** DatabaseOpenTask ***
 // Opens the database file and verifies the version matches the expected version.
 
-DatabaseBackendAsync::DatabaseOpenTask::DatabaseOpenTask(DatabaseBackendAsync* database, bool setVersionInNewDatabase, DatabaseTaskSynchronizer* synchronizer, DatabaseError& error, String& errorMessage, bool& success)
+DatabaseBackend::DatabaseOpenTask::DatabaseOpenTask(DatabaseBackend* database, bool setVersionInNewDatabase, DatabaseTaskSynchronizer* synchronizer, DatabaseError& error, String& errorMessage, bool& success)
     : DatabaseTask(database, synchronizer)
     , m_setVersionInNewDatabase(setVersionInNewDatabase)
     , m_error(error)
@@ -109,7 +109,7 @@ DatabaseBackendAsync::DatabaseOpenTask::DatabaseOpenTask(DatabaseBackendAsync* d
     ASSERT(synchronizer); // A task with output parameters is supposed to be synchronous.
 }
 
-void DatabaseBackendAsync::DatabaseOpenTask::doPerformTask()
+void DatabaseBackend::DatabaseOpenTask::doPerformTask()
 {
     String errorMessage;
     m_success = database()->performOpenAndVerify(m_setVersionInNewDatabase, m_error, errorMessage);
@@ -118,7 +118,7 @@ void DatabaseBackendAsync::DatabaseOpenTask::doPerformTask()
 }
 
 #if !LOG_DISABLED
-const char* DatabaseBackendAsync::DatabaseOpenTask::debugTaskName() const
+const char* DatabaseBackend::DatabaseOpenTask::debugTaskName() const
 {
     return "DatabaseOpenTask";
 }
@@ -127,18 +127,18 @@ const char* DatabaseBackendAsync::DatabaseOpenTask::debugTaskName() const
 // *** DatabaseCloseTask ***
 // Closes the database.
 
-DatabaseBackendAsync::DatabaseCloseTask::DatabaseCloseTask(DatabaseBackendAsync* database, DatabaseTaskSynchronizer* synchronizer)
+DatabaseBackend::DatabaseCloseTask::DatabaseCloseTask(DatabaseBackend* database, DatabaseTaskSynchronizer* synchronizer)
     : DatabaseTask(database, synchronizer)
 {
 }
 
-void DatabaseBackendAsync::DatabaseCloseTask::doPerformTask()
+void DatabaseBackend::DatabaseCloseTask::doPerformTask()
 {
     Database::from(database())->close();
 }
 
 #if !LOG_DISABLED
-const char* DatabaseBackendAsync::DatabaseCloseTask::debugTaskName() const
+const char* DatabaseBackend::DatabaseCloseTask::debugTaskName() const
 {
     return "DatabaseCloseTask";
 }
@@ -147,14 +147,14 @@ const char* DatabaseBackendAsync::DatabaseCloseTask::debugTaskName() const
 // *** DatabaseTransactionTask ***
 // Starts a transaction that will report its results via a callback.
 
-DatabaseBackendAsync::DatabaseTransactionTask::DatabaseTransactionTask(PassRefPtr<SQLTransactionBackend> transaction)
+DatabaseBackend::DatabaseTransactionTask::DatabaseTransactionTask(PassRefPtr<SQLTransactionBackend> transaction)
     : DatabaseTask(Database::from(transaction->database()), 0)
     , m_transaction(transaction)
     , m_didPerformTask(false)
 {
 }
 
-DatabaseBackendAsync::DatabaseTransactionTask::~DatabaseTransactionTask()
+DatabaseBackend::DatabaseTransactionTask::~DatabaseTransactionTask()
 {
     // If the task is being destructed without the transaction ever being run,
     // then we must either have an error or an interruption. Give the
@@ -168,14 +168,14 @@ DatabaseBackendAsync::DatabaseTransactionTask::~DatabaseTransactionTask()
         m_transaction->notifyDatabaseThreadIsShuttingDown();
 }
 
-void DatabaseBackendAsync::DatabaseTransactionTask::doPerformTask()
+void DatabaseBackend::DatabaseTransactionTask::doPerformTask()
 {
     m_transaction->performNextStep();
     m_didPerformTask = true;
 }
 
 #if !LOG_DISABLED
-const char* DatabaseBackendAsync::DatabaseTransactionTask::debugTaskName() const
+const char* DatabaseBackend::DatabaseTransactionTask::debugTaskName() const
 {
     return "DatabaseTransactionTask";
 }
@@ -184,20 +184,20 @@ const char* DatabaseBackendAsync::DatabaseTransactionTask::debugTaskName() const
 // *** DatabaseTableNamesTask ***
 // Retrieves a list of all tables in the database - for WebInspector support.
 
-DatabaseBackendAsync::DatabaseTableNamesTask::DatabaseTableNamesTask(DatabaseBackendAsync* database, DatabaseTaskSynchronizer* synchronizer, Vector<String>& names)
+DatabaseBackend::DatabaseTableNamesTask::DatabaseTableNamesTask(DatabaseBackend* database, DatabaseTaskSynchronizer* synchronizer, Vector<String>& names)
     : DatabaseTask(database, synchronizer)
     , m_tableNames(names)
 {
     ASSERT(synchronizer); // A task with output parameters is supposed to be synchronous.
 }
 
-void DatabaseBackendAsync::DatabaseTableNamesTask::doPerformTask()
+void DatabaseBackend::DatabaseTableNamesTask::doPerformTask()
 {
     m_tableNames = Database::from(database())->performGetTableNames();
 }
 
 #if !LOG_DISABLED
-const char* DatabaseBackendAsync::DatabaseTableNamesTask::debugTaskName() const
+const char* DatabaseBackend::DatabaseTableNamesTask::debugTaskName() const
 {
     return "DatabaseTableNamesTask";
 }
index dfd150e..ddbe73d 100644 (file)
@@ -30,7 +30,7 @@
 
 #if ENABLE(SQL_DATABASE)
 
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 #include "DatabaseBasicTypes.h"
 #include "DatabaseError.h"
 #include "SQLTransactionBackend.h"
@@ -77,19 +77,19 @@ public:
 
     void performTask();
 
-    DatabaseBackendAsync* database() const { return m_database; }
+    DatabaseBackend* database() const { return m_database; }
 #ifndef NDEBUG
     bool hasSynchronizer() const { return m_synchronizer; }
     bool hasCheckedForTermination() const { return m_synchronizer->hasCheckedForTermination(); }
 #endif
 
 protected:
-    DatabaseTask(DatabaseBackendAsync*, DatabaseTaskSynchronizer*);
+    DatabaseTask(DatabaseBackend*, DatabaseTaskSynchronizer*);
 
 private:
     virtual void doPerformTask() = 0;
 
-    DatabaseBackendAsync* m_database;
+    DatabaseBackend* m_database;
     DatabaseTaskSynchronizer* m_synchronizer;
 
 #if !LOG_DISABLED
@@ -98,15 +98,15 @@ private:
 #endif
 };
 
-class DatabaseBackendAsync::DatabaseOpenTask : public DatabaseTask {
+class DatabaseBackend::DatabaseOpenTask : public DatabaseTask {
 public:
-    static PassOwnPtr<DatabaseOpenTask> create(DatabaseBackendAsync* db, bool setVersionInNewDatabase, DatabaseTaskSynchronizer* synchronizer, DatabaseError& error, String& errorMessage, bool& success)
+    static PassOwnPtr<DatabaseOpenTask> create(DatabaseBackend* db, bool setVersionInNewDatabase, DatabaseTaskSynchronizer* synchronizer, DatabaseError& error, String& errorMessage, bool& success)
     {
         return adoptPtr(new DatabaseOpenTask(db, setVersionInNewDatabase, synchronizer, error, errorMessage, success));
     }
 
 private:
-    DatabaseOpenTask(DatabaseBackendAsync*, bool setVersionInNewDatabase, DatabaseTaskSynchronizer*, DatabaseError&, String& errorMessage, bool& success);
+    DatabaseOpenTask(DatabaseBackend*, bool setVersionInNewDatabase, DatabaseTaskSynchronizer*, DatabaseError&, String& errorMessage, bool& success);
 
     virtual void doPerformTask();
 #if !LOG_DISABLED
@@ -119,15 +119,15 @@ private:
     bool& m_success;
 };
 
-class DatabaseBackendAsync::DatabaseCloseTask : public DatabaseTask {
+class DatabaseBackend::DatabaseCloseTask : public DatabaseTask {
 public:
-    static PassOwnPtr<DatabaseCloseTask> create(DatabaseBackendAsync* db, DatabaseTaskSynchronizer* synchronizer)
+    static PassOwnPtr<DatabaseCloseTask> create(DatabaseBackend* db, DatabaseTaskSynchronizer* synchronizer)
     {
         return adoptPtr(new DatabaseCloseTask(db, synchronizer));
     }
 
 private:
-    DatabaseCloseTask(DatabaseBackendAsync*, DatabaseTaskSynchronizer*);
+    DatabaseCloseTask(DatabaseBackend*, DatabaseTaskSynchronizer*);
 
     virtual void doPerformTask();
 #if !LOG_DISABLED
@@ -135,7 +135,7 @@ private:
 #endif
 };
 
-class DatabaseBackendAsync::DatabaseTransactionTask : public DatabaseTask {
+class DatabaseBackend::DatabaseTransactionTask : public DatabaseTask {
 public:
     virtual ~DatabaseTransactionTask();
 
@@ -159,15 +159,15 @@ private:
     bool m_didPerformTask;
 };
 
-class DatabaseBackendAsync::DatabaseTableNamesTask : public DatabaseTask {
+class DatabaseBackend::DatabaseTableNamesTask : public DatabaseTask {
 public:
-    static PassOwnPtr<DatabaseTableNamesTask> create(DatabaseBackendAsync* db, DatabaseTaskSynchronizer* synchronizer, Vector<String>& names)
+    static PassOwnPtr<DatabaseTableNamesTask> create(DatabaseBackend* db, DatabaseTaskSynchronizer* synchronizer, Vector<String>& names)
     {
         return adoptPtr(new DatabaseTableNamesTask(db, synchronizer, names));
     }
 
 private:
-    DatabaseTableNamesTask(DatabaseBackendAsync*, DatabaseTaskSynchronizer*, Vector<String>& names);
+    DatabaseTableNamesTask(DatabaseBackend*, DatabaseTaskSynchronizer*, Vector<String>& names);
 
     virtual void doPerformTask();
 #if !LOG_DISABLED
index e4883f6..e74a1b2 100644 (file)
@@ -141,7 +141,7 @@ void DatabaseThread::databaseThread()
         cleanupSync->taskCompleted();
 }
 
-void DatabaseThread::recordDatabaseOpen(DatabaseBackendAsync* database)
+void DatabaseThread::recordDatabaseOpen(DatabaseBackend* database)
 {
     ASSERT(currentThread() == m_threadID);
     ASSERT(database);
@@ -149,7 +149,7 @@ void DatabaseThread::recordDatabaseOpen(DatabaseBackendAsync* database)
     m_openDatabaseSet.add(database);
 }
 
-void DatabaseThread::recordDatabaseClosed(DatabaseBackendAsync* database)
+void DatabaseThread::recordDatabaseClosed(DatabaseBackend* database)
 {
     ASSERT(currentThread() == m_threadID);
     ASSERT(database);
@@ -171,13 +171,13 @@ void DatabaseThread::scheduleImmediateTask(PassOwnPtr<DatabaseTask> task)
 
 class SameDatabasePredicate {
 public:
-    SameDatabasePredicate(const DatabaseBackendAsync* database) : m_database(database) { }
+    SameDatabasePredicate(const DatabaseBackend* database) : m_database(database) { }
     bool operator()(DatabaseTask* task) const { return task->database() == m_database; }
 private:
-    const DatabaseBackendAsync* m_database;
+    const DatabaseBackend* m_database;
 };
 
-void DatabaseThread::unscheduleDatabaseTasks(DatabaseBackendAsync* database)
+void DatabaseThread::unscheduleDatabaseTasks(DatabaseBackend* database)
 {
     // Note that the thread loop is running, so some tasks for the database
     // may still be executed. This is unavoidable.
index ce1a423..305d2ae 100644 (file)
@@ -42,7 +42,7 @@
 
 namespace WebCore {
 
-class DatabaseBackendAsync;
+class DatabaseBackend;
 class DatabaseTask;
 class DatabaseTaskSynchronizer;
 class Document;
@@ -60,10 +60,10 @@ public:
 
     void scheduleTask(PassOwnPtr<DatabaseTask>);
     void scheduleImmediateTask(PassOwnPtr<DatabaseTask>); // This just adds the task to the front of the queue - the caller needs to be extremely careful not to create deadlocks when waiting for completion.
-    void unscheduleDatabaseTasks(DatabaseBackendAsync*);
+    void unscheduleDatabaseTasks(DatabaseBackend*);
 
-    void recordDatabaseOpen(DatabaseBackendAsync*);
-    void recordDatabaseClosed(DatabaseBackendAsync*);
+    void recordDatabaseOpen(DatabaseBackend*);
+    void recordDatabaseClosed(DatabaseBackend*);
     ThreadIdentifier getThreadID() { return m_threadID; }
 
     SQLTransactionClient* transactionClient() { return m_transactionClient.get(); }
@@ -82,7 +82,7 @@ private:
     MessageQueue<DatabaseTask> m_queue;
 
     // This set keeps track of the open databases that have been used on this thread.
-    typedef HashSet<RefPtr<DatabaseBackendAsync> > DatabaseSet;
+    typedef HashSet<RefPtr<DatabaseBackend> > DatabaseSet;
     DatabaseSet m_openDatabaseSet;
 
     OwnPtr<SQLTransactionClient> m_transactionClient;
index 38528db..0d22704 100644 (file)
@@ -31,7 +31,7 @@
 #if ENABLE(SQL_DATABASE)
 
 #include "AbstractSQLStatement.h"
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 #include "Logging.h"
 #include "SQLError.h"
 #include "SQLValue.h"
@@ -107,7 +107,7 @@ PassRefPtr<SQLResultSet> SQLStatementBackend::sqlResultSet() const
     return m_resultSet;
 }
 
-bool SQLStatementBackend::execute(DatabaseBackendAsync* db)
+bool SQLStatementBackend::execute(DatabaseBackend* db)
 {
     ASSERT(!m_resultSet);
 
@@ -211,21 +211,21 @@ bool SQLStatementBackend::execute(DatabaseBackendAsync* db)
     return true;
 }
 
-void SQLStatementBackend::setDatabaseDeletedError(DatabaseBackendAsync* database)
+void SQLStatementBackend::setDatabaseDeletedError(DatabaseBackend* database)
 {
     ASSERT(!m_error && !m_resultSet);
     database->reportExecuteStatementResult(6, SQLError::UNKNOWN_ERR, 0);
     m_error = SQLError::create(SQLError::UNKNOWN_ERR, "unable to execute statement, because the user deleted the database");
 }
 
-void SQLStatementBackend::setVersionMismatchedError(DatabaseBackendAsync* database)
+void SQLStatementBackend::setVersionMismatchedError(DatabaseBackend* database)
 {
     ASSERT(!m_error && !m_resultSet);
     database->reportExecuteStatementResult(7, SQLError::VERSION_ERR, 0);
     m_error = SQLError::create(SQLError::VERSION_ERR, "current version of the database and `oldVersion` argument do not match");
 }
 
-void SQLStatementBackend::setFailureDueToQuota(DatabaseBackendAsync* database)
+void SQLStatementBackend::setFailureDueToQuota(DatabaseBackend* database)
 {
     ASSERT(!m_error && !m_resultSet);
     database->reportExecuteStatementResult(8, SQLError::QUOTA_ERR, 0);
index f3e7f92..8e72132 100644 (file)
@@ -40,7 +40,7 @@
 namespace WebCore {
 
 class AbstractSQLStatement;
-class DatabaseBackendAsync;
+class DatabaseBackend;
 class SQLError;
 class SQLTransactionBackend;
 
@@ -49,14 +49,14 @@ public:
     static PassRefPtr<SQLStatementBackend> create(PassOwnPtr<AbstractSQLStatement>,
         const String& sqlStatement, const Vector<SQLValue>& arguments, int permissions);
 
-    bool execute(DatabaseBackendAsync*);
+    bool execute(DatabaseBackend*);
     bool lastExecutionFailedDueToQuota() const;
 
     bool hasStatementCallback() const { return m_hasCallback; }
     bool hasStatementErrorCallback() const { return m_hasErrorCallback; }
 
-    void setDatabaseDeletedError(DatabaseBackendAsync*);
-    void setVersionMismatchedError(DatabaseBackendAsync*);
+    void setDatabaseDeletedError(DatabaseBackend*);
+    void setVersionMismatchedError(DatabaseBackend*);
 
     AbstractSQLStatement* frontend();
     virtual PassRefPtr<SQLError> sqlError() const;
@@ -66,7 +66,7 @@ private:
     SQLStatementBackend(PassOwnPtr<AbstractSQLStatement>, const String& statement,
         const Vector<SQLValue>& arguments, int permissions);
 
-    void setFailureDueToQuota(DatabaseBackendAsync*);
+    void setFailureDueToQuota(DatabaseBackend*);
     void clearFailureDueToQuota();
 
     OwnPtr<AbstractSQLStatement> m_frontend;
index d399a4a..c400a1d 100644 (file)
@@ -34,7 +34,7 @@
 #include "AbstractSQLTransaction.h"
 #include "Database.h" // FIXME: Should only be used in the frontend.
 #include "DatabaseAuthorizer.h"
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 #include "DatabaseBackendContext.h"
 #include "DatabaseThread.h"
 #include "ExceptionCode.h"
 // ==============================================================================
 // The RefPtr chain goes something like this:
 //
-//     At birth (in DatabaseBackendAsync::runTransaction()):
+//     At birth (in DatabaseBackend::runTransaction()):
 //     ====================================================
-//     DatabaseBackendAsync               // Deque<RefPtr<SQLTransactionBackend> > m_transactionQueue points to ...
+//     DatabaseBackend                    // Deque<RefPtr<SQLTransactionBackend> > m_transactionQueue points to ...
 //     --> SQLTransactionBackend          // RefPtr<SQLTransaction> m_frontend points to ...
 //         --> SQLTransaction             // RefPtr<SQLTransactionBackend> m_backend points to ...
 //             --> SQLTransactionBackend  // which is a circular reference.
 //     or if the database was interrupted. See comments on "What happens if a transaction
 //     is interrupted?" below for details.
 //
-//     After scheduling the transaction with the DatabaseThread (DatabaseBackendAsync::scheduleTransaction()):
+//     After scheduling the transaction with the DatabaseThread (DatabaseBackend::scheduleTransaction()):
 //     ======================================================================================================
 //     DatabaseThread                         // MessageQueue<DatabaseTask> m_queue points to ...
 //     --> DatabaseTransactionTask            // RefPtr<SQLTransactionBackend> m_transaction points to ...
 //     Phase 1. After Birth, before scheduling
 //
 //     - To clean up, DatabaseThread::databaseThread() will call
-//       DatabaseBackendAsync::close() during its shutdown.
-//     - DatabaseBackendAsync::close() will iterate
-//       DatabaseBackendAsync::m_transactionQueue and call
+//       DatabaseBackend::close() during its shutdown.
+//     - DatabaseBackend::close() will iterate
+//       DatabaseBackend::m_transactionQueue and call
 //       notifyDatabaseThreadIsShuttingDown() on each transaction there.
 //        
 //     Phase 2. After scheduling, before state AcquireLock
@@ -348,13 +348,13 @@ static const int DefaultQuotaSizeIncrease = 1048576;
 
 namespace WebCore {
 
-PassRefPtr<SQLTransactionBackend> SQLTransactionBackend::create(DatabaseBackendAsync* db,
+PassRefPtr<SQLTransactionBackend> SQLTransactionBackend::create(DatabaseBackend* db,
     PassRefPtr<AbstractSQLTransaction> frontend, PassRefPtr<SQLTransactionWrapper> wrapper, bool readOnly)
 {
     return adoptRef(new SQLTransactionBackend(db, frontend, wrapper, readOnly));
 }
 
-SQLTransactionBackend::SQLTransactionBackend(DatabaseBackendAsync* db,
+SQLTransactionBackend::SQLTransactionBackend(DatabaseBackend* db,
     PassRefPtr<AbstractSQLTransaction> frontend, PassRefPtr<SQLTransactionWrapper> wrapper, bool readOnly)
     : m_frontend(frontend)
     , m_database(db)
index b07df41..ce5459f 100644 (file)
@@ -41,7 +41,7 @@
 namespace WebCore {
 
 class AbstractSQLTransaction;
-class DatabaseBackendAsync;
+class DatabaseBackend;
 class SQLError;
 class SQLiteTransaction;
 class SQLStatementBackend;
@@ -59,7 +59,7 @@ public:
 
 class SQLTransactionBackend : public SQLTransactionStateMachine<SQLTransactionBackend>, public AbstractSQLTransactionBackend {
 public:
-    static PassRefPtr<SQLTransactionBackend> create(DatabaseBackendAsync*,
+    static PassRefPtr<SQLTransactionBackend> create(DatabaseBackend*,
         PassRefPtr<AbstractSQLTransaction>, PassRefPtr<SQLTransactionWrapper>, bool readOnly);
 
     virtual ~SQLTransactionBackend();
@@ -67,12 +67,12 @@ public:
     void lockAcquired();
     void performNextStep();
 
-    DatabaseBackendAsync* database() { return m_database.get(); }
+    DatabaseBackend* database() { return m_database.get(); }
     bool isReadOnly() { return m_readOnly; }
     void notifyDatabaseThreadIsShuttingDown();
 
 private:
-    SQLTransactionBackend(DatabaseBackendAsync*, PassRefPtr<AbstractSQLTransaction>,
+    SQLTransactionBackend(DatabaseBackend*, PassRefPtr<AbstractSQLTransaction>,
         PassRefPtr<SQLTransactionWrapper>, bool readOnly);
 
     // APIs called from the frontend published via AbstractSQLTransactionBackend:
@@ -111,7 +111,7 @@ private:
     RefPtr<AbstractSQLTransaction> m_frontend; // Has a reference cycle, and will break in doCleanup().
     RefPtr<SQLStatementBackend> m_currentStatementBackend;
 
-    RefPtr<DatabaseBackendAsync> m_database;
+    RefPtr<DatabaseBackend> m_database;
     RefPtr<SQLTransactionWrapper> m_wrapper;
     RefPtr<SQLError> m_transactionError;
 
index 48a9c89..295c24d 100644 (file)
@@ -34,7 +34,7 @@
 
 #if ENABLE(SQL_DATABASE)
 
-#include "DatabaseBackendAsync.h"
+#include "DatabaseBackend.h"
 #include "SQLTransactionBackend.h"
 #include <wtf/Deque.h>
 #include <wtf/HashMap.h>
@@ -45,7 +45,7 @@ namespace WebCore {
 
 static String getDatabaseIdentifier(SQLTransactionBackend* transaction)
 {
-    DatabaseBackendAsync* database = transaction->database();
+    DatabaseBackend* database = transaction->database();
     ASSERT(database);
     return database->stringIdentifier();
 }
index 9a45b9d..9a09a04 100644 (file)
@@ -1464,7 +1464,7 @@ HEADERS += \
     Modules/webdatabase/DOMWindowWebDatabase.h \
     Modules/webdatabase/DatabaseAuthorizer.h \
     Modules/webdatabase/Database.h \
-    Modules/webdatabase/DatabaseBackendAsync.h \
+    Modules/webdatabase/DatabaseBackend.h \
     Modules/webdatabase/DatabaseBackendBase.h \
     Modules/webdatabase/DatabaseBackendContext.h \
     Modules/webdatabase/DatabaseBackendSync.h \
@@ -3063,7 +3063,7 @@ use?(PLUGIN_BACKEND_XLIB) {
 enable?(SQL_DATABASE) {
     SOURCES += \
         Modules/webdatabase/ChangeVersionWrapper.cpp \
-        Modules/webdatabase/DatabaseBackendAsync.cpp \
+        Modules/webdatabase/DatabaseBackend.cpp \
         Modules/webdatabase/DatabaseBackendContext.cpp \
         Modules/webdatabase/DatabaseBackendSync.cpp \
         Modules/webdatabase/DatabaseBase.cpp \
index b3a5165..f774445 100644 (file)
             'Modules/webdatabase/Database.cpp',
             'Modules/webdatabase/DatabaseAuthorizer.cpp',
             'Modules/webdatabase/DatabaseAuthorizer.h',
-            'Modules/webdatabase/DatabaseBackendAsync.cpp',
-            'Modules/webdatabase/DatabaseBackendAsync.h',
+            'Modules/webdatabase/DatabaseBackend.cpp',
+            'Modules/webdatabase/DatabaseBackend.h',
             'Modules/webdatabase/DatabaseBackendBase.cpp',
             'Modules/webdatabase/DatabaseBackendBase.h',
             'Modules/webdatabase/DatabaseBackendContext.cpp',
index 6fc5332..674e945 100755 (executable)
                                        >
                                </File>
                                <File
-                                       RelativePath="..\Modules\webdatabase\DatabaseBackendAsync.cpp"
+                                       RelativePath="..\Modules\webdatabase\DatabaseBackend.cpp"
                                        >
                                </File>
                                <File
-                                       RelativePath="..\Modules\webdatabase\DatabaseBackendAsync.h"
+                                       RelativePath="..\Modules\webdatabase\DatabaseBackend.h"
                                        >
                                </File>
                                <File
index 436843f..8a3cc54 100644 (file)
     <ClCompile Include="..\Modules\webdatabase\ChangeVersionWrapper.cpp" />
     <ClCompile Include="..\Modules\webdatabase\Database.cpp" />
     <ClCompile Include="..\Modules\webdatabase\DatabaseAuthorizer.cpp" />
-    <ClCompile Include="..\Modules\webdatabase\DatabaseBackendAsync.cpp" />
+    <ClCompile Include="..\Modules\webdatabase\DatabaseBackend.cpp" />
     <ClCompile Include="..\Modules\webdatabase\DatabaseBackendBase.cpp" />
     <ClCompile Include="..\Modules\webdatabase\DatabaseBackendContext.cpp" />
     <ClCompile Include="..\Modules\webdatabase\DatabaseBackendSync.cpp" />
     <ClInclude Include="..\Modules\webdatabase\ChangeVersionWrapper.h" />
     <ClInclude Include="..\Modules\webdatabase\Database.h" />
     <ClInclude Include="..\Modules\webdatabase\DatabaseAuthorizer.h" />
-    <ClInclude Include="..\Modules\webdatabase\DatabaseBackendAsync.h" />
+    <ClInclude Include="..\Modules\webdatabase\DatabaseBackend.h" />
     <ClInclude Include="..\Modules\webdatabase\DatabaseBackendBase.h" />
     <ClInclude Include="..\Modules\webdatabase\DatabaseBackendContext.h" />
     <ClInclude Include="..\Modules\webdatabase\DatabaseBackendSync.h" />
index 2a89bed..1dafa68 100644 (file)
     <ClCompile Include="..\Modules\webdatabase\DatabaseAuthorizer.cpp">
       <Filter>Modules\webdatabase</Filter>
     </ClCompile>
-    <ClCompile Include="..\Modules\webdatabase\DatabaseBackendAsync.cpp">
+    <ClCompile Include="..\Modules\webdatabase\DatabaseBackend.cpp">
       <Filter>Modules\webdatabase</Filter>
     </ClCompile>
     <ClCompile Include="..\Modules\webdatabase\DatabaseBackendBase.cpp">
     <ClInclude Include="..\Modules\webdatabase\DatabaseAuthorizer.h">
       <Filter>Modules\webdatabase</Filter>
     </ClInclude>
-    <ClInclude Include="..\Modules\webdatabase\DatabaseBackendAsync.h">
+    <ClInclude Include="..\Modules\webdatabase\DatabaseBackend.h">
       <Filter>Modules\webdatabase</Filter>
     </ClInclude>
     <ClInclude Include="..\Modules\webdatabase\DatabaseBackendBase.h">
index effe890..ff7f491 100644 (file)
                FDF7E9C413AC21DB00A51EAC /* JSAudioBufferCallback.h in Headers */ = {isa = PBXBuildFile; fileRef = FDF7E9C213AC21DB00A51EAC /* JSAudioBufferCallback.h */; };
                FE09DB49169E2D6E00622557 /* DatabaseError.h in Headers */ = {isa = PBXBuildFile; fileRef = FE09DB46169E2D6E00622557 /* DatabaseError.h */; settings = {ATTRIBUTES = (Private, ); }; };
                FE115FAB167988CD00249134 /* AbstractDatabaseServer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE115FA9167988CD00249134 /* AbstractDatabaseServer.h */; settings = {ATTRIBUTES = (Private, ); }; };
-               FE16CFD3169D1DED00D3A0C7 /* DatabaseBackendAsync.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE16CFCF169D1DEC00D3A0C7 /* DatabaseBackendAsync.cpp */; };
-               FE16CFD4169D1DED00D3A0C7 /* DatabaseBackendAsync.h in Headers */ = {isa = PBXBuildFile; fileRef = FE16CFD0169D1DEC00D3A0C7 /* DatabaseBackendAsync.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               FE16CFD3169D1DED00D3A0C7 /* DatabaseBackend.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE16CFCF169D1DEC00D3A0C7 /* DatabaseBackend.cpp */; };
+               FE16CFD4169D1DED00D3A0C7 /* DatabaseBackend.h in Headers */ = {isa = PBXBuildFile; fileRef = FE16CFD0169D1DEC00D3A0C7 /* DatabaseBackend.h */; settings = {ATTRIBUTES = (Private, ); }; };
                FE16CFD5169D1DED00D3A0C7 /* DatabaseBackendSync.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE16CFD1169D1DEC00D3A0C7 /* DatabaseBackendSync.cpp */; };
                FE16CFD6169D1DED00D3A0C7 /* DatabaseBackendSync.h in Headers */ = {isa = PBXBuildFile; fileRef = FE16CFD2169D1DEC00D3A0C7 /* DatabaseBackendSync.h */; settings = {ATTRIBUTES = (Private, ); }; };
                FE3371A2167C11D400EDB752 /* DatabaseBasicTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = FE3371A0167C11D400EDB752 /* DatabaseBasicTypes.h */; settings = {ATTRIBUTES = (Private, ); }; };
                FDF7E9C213AC21DB00A51EAC /* JSAudioBufferCallback.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSAudioBufferCallback.h; sourceTree = "<group>"; };
                FE09DB46169E2D6E00622557 /* DatabaseError.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DatabaseError.h; path = Modules/webdatabase/DatabaseError.h; sourceTree = "<group>"; };
                FE115FA9167988CD00249134 /* AbstractDatabaseServer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AbstractDatabaseServer.h; path = Modules/webdatabase/AbstractDatabaseServer.h; sourceTree = "<group>"; };
-               FE16CFCF169D1DEC00D3A0C7 /* DatabaseBackendAsync.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DatabaseBackendAsync.cpp; path = Modules/webdatabase/DatabaseBackendAsync.cpp; sourceTree = "<group>"; };
-               FE16CFD0169D1DEC00D3A0C7 /* DatabaseBackendAsync.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DatabaseBackendAsync.h; path = Modules/webdatabase/DatabaseBackendAsync.h; sourceTree = "<group>"; };
+               FE16CFCF169D1DEC00D3A0C7 /* DatabaseBackend.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DatabaseBackend.cpp; path = Modules/webdatabase/DatabaseBackend.cpp; sourceTree = "<group>"; };
+               FE16CFD0169D1DEC00D3A0C7 /* DatabaseBackend.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DatabaseBackend.h; path = Modules/webdatabase/DatabaseBackend.h; sourceTree = "<group>"; };
                FE16CFD1169D1DEC00D3A0C7 /* DatabaseBackendSync.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DatabaseBackendSync.cpp; path = Modules/webdatabase/DatabaseBackendSync.cpp; sourceTree = "<group>"; };
                FE16CFD2169D1DEC00D3A0C7 /* DatabaseBackendSync.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DatabaseBackendSync.h; path = Modules/webdatabase/DatabaseBackendSync.h; sourceTree = "<group>"; };
                FE3371A0167C11D400EDB752 /* DatabaseBasicTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DatabaseBasicTypes.h; path = Modules/webdatabase/DatabaseBasicTypes.h; sourceTree = "<group>"; };
                                97BC69E01505F081001B74AC /* Database.idl */,
                                97BC69E11505F081001B74AC /* DatabaseAuthorizer.cpp */,
                                97BC69E21505F081001B74AC /* DatabaseAuthorizer.h */,
-                               FE16CFCF169D1DEC00D3A0C7 /* DatabaseBackendAsync.cpp */,
-                               FE16CFD0169D1DEC00D3A0C7 /* DatabaseBackendAsync.h */,
+                               FE16CFCF169D1DEC00D3A0C7 /* DatabaseBackend.cpp */,
+                               FE16CFD0169D1DEC00D3A0C7 /* DatabaseBackend.h */,
                                97BC69D61505F076001B74AC /* DatabaseBackendBase.cpp */,
                                97BC69D71505F076001B74AC /* DatabaseBackendBase.h */,
                                FE6F6AAD169E057500FC30A2 /* DatabaseBackendContext.cpp */,
                                A80E6D0B0A1989CA007FB8C5 /* DashboardRegion.h in Headers */,
                                97BC6A211505F081001B74AC /* Database.h in Headers */,
                                97BC6A241505F081001B74AC /* DatabaseAuthorizer.h in Headers */,
-                               FE16CFD4169D1DED00D3A0C7 /* DatabaseBackendAsync.h in Headers */,
+                               FE16CFD4169D1DED00D3A0C7 /* DatabaseBackend.h in Headers */,
                                97BC69DB1505F076001B74AC /* DatabaseBackendBase.h in Headers */,
                                FE6F6AB0169E057500FC30A2 /* DatabaseBackendContext.h in Headers */,
                                FE16CFD6169D1DED00D3A0C7 /* DatabaseBackendSync.h in Headers */,
                                A29532CF15DD5E1700469EBC /* CustomFilterValidatedProgram.cpp in Sources */,
                                97BC6A201505F081001B74AC /* Database.cpp in Sources */,
                                97BC6A231505F081001B74AC /* DatabaseAuthorizer.cpp in Sources */,
-                               FE16CFD3169D1DED00D3A0C7 /* DatabaseBackendAsync.cpp in Sources */,
+                               FE16CFD3169D1DED00D3A0C7 /* DatabaseBackend.cpp in Sources */,
                                97BC69DA1505F076001B74AC /* DatabaseBackendBase.cpp in Sources */,
                                FE6F6AAF169E057500FC30A2 /* DatabaseBackendContext.cpp in Sources */,
                                FE16CFD5169D1DED00D3A0C7 /* DatabaseBackendSync.cpp in Sources */,