<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[188004] trunk/Source/WebCore</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/188004">188004</a></dd>
<dt>Author</dt> <dd>andersca@apple.com</dd>
<dt>Date</dt> <dd>2015-08-05 16:50:06 -0700 (Wed, 05 Aug 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>Move the last DatabaseBackendBase functions over to Database
https://bugs.webkit.org/show_bug.cgi?id=147706

Reviewed by Tim Horton.

* Modules/webdatabase/Database.cpp:
(WebCore::Database::~Database):
(WebCore::Database::setExpectedVersion):
(WebCore::Database::getActualVersionForTransaction):
(WebCore::Database::version):
(WebCore::Database::stringIdentifier):
(WebCore::Database::displayName):
(WebCore::Database::estimatedSize):
(WebCore::Database::fileName):
(WebCore::Database::details):
(WebCore::Database::maximumSize):
(WebCore::Database::databaseDebugName):
* Modules/webdatabase/Database.h:
* Modules/webdatabase/DatabaseBackendBase.cpp:
(WebCore::DatabaseBackendBase::databaseDebugName): Deleted.
(WebCore::DatabaseBackendBase::~DatabaseBackendBase): Deleted.
(WebCore::DatabaseBackendBase::version): Deleted.
(WebCore::DatabaseBackendBase::securityOrigin): Deleted.
(WebCore::DatabaseBackendBase::stringIdentifier): Deleted.
(WebCore::DatabaseBackendBase::displayName): Deleted.
(WebCore::DatabaseBackendBase::estimatedSize): Deleted.
(WebCore::DatabaseBackendBase::fileName): Deleted.
(WebCore::DatabaseBackendBase::details): Deleted.
(WebCore::DatabaseBackendBase::setExpectedVersion): Deleted.
(WebCore::DatabaseBackendBase::getActualVersionForTransaction): Deleted.
(WebCore::DatabaseBackendBase::maximumSize): Deleted.
* Modules/webdatabase/DatabaseBackendBase.h:
(WebCore::DatabaseBackendBase::opened): Deleted.
(WebCore::DatabaseBackendBase::isNew): Deleted.
(WebCore::DatabaseBackendBase::sqliteDatabase): Deleted.
(WebCore::DatabaseBackendBase::expectedVersion): Deleted.
* Modules/webdatabase/SQLTransactionClient.cpp:
(WebCore::SQLTransactionClient::didCommitWriteTransaction):
(WebCore::SQLTransactionClient::didExceedQuota):
* Modules/webdatabase/SQLTransactionClient.h:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreModuleswebdatabaseDatabasecpp">trunk/Source/WebCore/Modules/webdatabase/Database.cpp</a></li>
<li><a href="#trunkSourceWebCoreModuleswebdatabaseDatabaseh">trunk/Source/WebCore/Modules/webdatabase/Database.h</a></li>
<li><a href="#trunkSourceWebCoreModuleswebdatabaseDatabaseBackendBasecpp">trunk/Source/WebCore/Modules/webdatabase/DatabaseBackendBase.cpp</a></li>
<li><a href="#trunkSourceWebCoreModuleswebdatabaseDatabaseBackendBaseh">trunk/Source/WebCore/Modules/webdatabase/DatabaseBackendBase.h</a></li>
<li><a href="#trunkSourceWebCoreModuleswebdatabaseSQLTransactionClientcpp">trunk/Source/WebCore/Modules/webdatabase/SQLTransactionClient.cpp</a></li>
<li><a href="#trunkSourceWebCoreModuleswebdatabaseSQLTransactionClienth">trunk/Source/WebCore/Modules/webdatabase/SQLTransactionClient.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (188003 => 188004)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2015-08-05 23:49:51 UTC (rev 188003)
+++ trunk/Source/WebCore/ChangeLog        2015-08-05 23:50:06 UTC (rev 188004)
</span><span class="lines">@@ -1,3 +1,46 @@
</span><ins>+2015-08-05  Anders Carlsson  &lt;andersca@apple.com&gt;
+
+        Move the last DatabaseBackendBase functions over to Database
+        https://bugs.webkit.org/show_bug.cgi?id=147706
+
+        Reviewed by Tim Horton.
+
+        * Modules/webdatabase/Database.cpp:
+        (WebCore::Database::~Database):
+        (WebCore::Database::setExpectedVersion):
+        (WebCore::Database::getActualVersionForTransaction):
+        (WebCore::Database::version):
+        (WebCore::Database::stringIdentifier):
+        (WebCore::Database::displayName):
+        (WebCore::Database::estimatedSize):
+        (WebCore::Database::fileName):
+        (WebCore::Database::details):
+        (WebCore::Database::maximumSize):
+        (WebCore::Database::databaseDebugName):
+        * Modules/webdatabase/Database.h:
+        * Modules/webdatabase/DatabaseBackendBase.cpp:
+        (WebCore::DatabaseBackendBase::databaseDebugName): Deleted.
+        (WebCore::DatabaseBackendBase::~DatabaseBackendBase): Deleted.
+        (WebCore::DatabaseBackendBase::version): Deleted.
+        (WebCore::DatabaseBackendBase::securityOrigin): Deleted.
+        (WebCore::DatabaseBackendBase::stringIdentifier): Deleted.
+        (WebCore::DatabaseBackendBase::displayName): Deleted.
+        (WebCore::DatabaseBackendBase::estimatedSize): Deleted.
+        (WebCore::DatabaseBackendBase::fileName): Deleted.
+        (WebCore::DatabaseBackendBase::details): Deleted.
+        (WebCore::DatabaseBackendBase::setExpectedVersion): Deleted.
+        (WebCore::DatabaseBackendBase::getActualVersionForTransaction): Deleted.
+        (WebCore::DatabaseBackendBase::maximumSize): Deleted.
+        * Modules/webdatabase/DatabaseBackendBase.h:
+        (WebCore::DatabaseBackendBase::opened): Deleted.
+        (WebCore::DatabaseBackendBase::isNew): Deleted.
+        (WebCore::DatabaseBackendBase::sqliteDatabase): Deleted.
+        (WebCore::DatabaseBackendBase::expectedVersion): Deleted.
+        * Modules/webdatabase/SQLTransactionClient.cpp:
+        (WebCore::SQLTransactionClient::didCommitWriteTransaction):
+        (WebCore::SQLTransactionClient::didExceedQuota):
+        * Modules/webdatabase/SQLTransactionClient.h:
+
</ins><span class="cx"> 2015-08-05  Filip Pizlo  &lt;fpizlo@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Unreviewed, roll out http://trac.webkit.org/changeset/187972.
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebdatabaseDatabasecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/webdatabase/Database.cpp (188003 => 188004)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/webdatabase/Database.cpp        2015-08-05 23:49:51 UTC (rev 188003)
+++ trunk/Source/WebCore/Modules/webdatabase/Database.cpp        2015-08-05 23:50:06 UTC (rev 188004)
</span><span class="lines">@@ -228,6 +228,17 @@
</span><span class="cx">             RefPtr&lt;ScriptExecutionContext&gt; scriptExecutionContext(passedContext);
</span><span class="cx">         }});
</span><span class="cx">     }
</span><ins>+
+    // SQLite is &quot;multi-thread safe&quot;, but each database handle can only be used
+    // on a single thread at a time.
+    //
+    // 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
+    // database should have already been closed.
+
+    ASSERT(!m_opened);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> bool Database::openAndVerifyVersion(bool setVersionInNewDatabase, DatabaseError&amp; error, String&amp; errorMessage)
</span><span class="lines">@@ -473,6 +484,11 @@
</span><span class="cx">     return result;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void Database::setExpectedVersion(const String&amp; version)
+{
+    m_expectedVersion = version.isolatedCopy();
+}
+
</ins><span class="cx"> String Database::getCachedVersion() const
</span><span class="cx"> {
</span><span class="cx">     std::lock_guard&lt;std::mutex&gt; locker(guidMutex());
</span><span class="lines">@@ -488,6 +504,15 @@
</span><span class="cx">     updateGuidVersionMap(m_guid, actualVersion);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool Database::getActualVersionForTransaction(String &amp;actualVersion)
+{
+    ASSERT(m_sqliteDatabase.transactionInProgress());
+
+    // Note: In multi-process browsers the cached value may be inaccurate.
+    // So we retrieve the value from the database and update the cached value here.
+    return getVersionFromDatabase(actualVersion, true);
+}
+
</ins><span class="cx"> void Database::scheduleTransaction()
</span><span class="cx"> {
</span><span class="cx">     ASSERT(!m_transactionInProgressMutex.tryLock()); // Locked by caller.
</span><span class="lines">@@ -560,7 +585,11 @@
</span><span class="cx"> {
</span><span class="cx">     if (m_deleted)
</span><span class="cx">         return String();
</span><del>-    return DatabaseBackendBase::version();
</del><ins>+
+    // Note: In multi-process browsers the cached value may be accurate, but we cannot read the
+    // actual version from the database without potentially inducing a deadlock.
+    // FIXME: Add an async version getter to the DatabaseAPI.
+    return getCachedVersion();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void Database::markAsDeletedAndClose()
</span><span class="lines">@@ -600,6 +629,35 @@
</span><span class="cx">     runTransaction(callback, errorCallback, successCallback, true);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+String Database::stringIdentifier() const
+{
+    // Return a deep copy for ref counting thread safety
+    return m_name.isolatedCopy();
+}
+
+String Database::displayName() const
+{
+    // Return a deep copy for ref counting thread safety
+    return m_displayName.isolatedCopy();
+}
+
+unsigned long Database::estimatedSize() const
+{
+    return m_estimatedSize;
+}
+
+String Database::fileName() const
+{
+    // Return a deep copy for ref counting thread safety
+    return m_filename.isolatedCopy();
+}
+
+DatabaseDetails Database::details() const
+{
+    // This code path is only used for database quota delegate calls, so file dates are irrelevant and left uninitialized.
+    return DatabaseDetails(stringIdentifier(), displayName(), estimatedSize(), 0, 0, 0);
+}
+
</ins><span class="cx"> void Database::disableAuthorizer()
</span><span class="cx"> {
</span><span class="cx">     ASSERT(m_databaseAuthorizer);
</span><span class="lines">@@ -741,4 +799,16 @@
</span><span class="cx">     return 0;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+unsigned long long Database::maximumSize() const
+{
+    return DatabaseTracker::tracker().getMaxSizeForDatabase(this);
+}
+
+#if !LOG_DISABLED || !ERROR_DISABLED
+String Database::databaseDebugName() const
+{
+    return m_contextThreadSecurityOrigin-&gt;toString() + &quot;::&quot; + m_name;
+}
+#endif
+
</ins><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebdatabaseDatabaseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/webdatabase/Database.h (188003 => 188004)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/webdatabase/Database.h        2015-08-05 23:49:51 UTC (rev 188003)
+++ trunk/Source/WebCore/Modules/webdatabase/Database.h        2015-08-05 23:50:06 UTC (rev 188004)
</span><span class="lines">@@ -57,6 +57,11 @@
</span><span class="cx">     virtual bool openAndVerifyVersion(bool setVersionInNewDatabase, DatabaseError&amp;, String&amp; errorMessage);
</span><span class="cx">     void close();
</span><span class="cx"> 
</span><ins>+    bool opened() const { return m_opened; }
+    bool isNew() const { return m_new; }
+
+    unsigned long long maximumSize() const;
+
</ins><span class="cx">     PassRefPtr&lt;SQLTransactionBackend&gt; runTransaction(PassRefPtr&lt;SQLTransaction&gt;, bool readOnly, const ChangeVersionData*);
</span><span class="cx">     void scheduleTransactionStep(SQLTransactionBackend*);
</span><span class="cx">     void inProgressTransactionCompleted();
</span><span class="lines">@@ -70,13 +75,20 @@
</span><span class="cx">     SQLTransactionCoordinator* transactionCoordinator() const;
</span><span class="cx"> 
</span><span class="cx">     // Direct support for the DOM API
</span><del>-    virtual String version() const;
</del><ins>+    String version() const;
</ins><span class="cx">     void changeVersion(const String&amp; oldVersion, const String&amp; newVersion, PassRefPtr&lt;SQLTransactionCallback&gt;,
</span><span class="cx">                        PassRefPtr&lt;SQLTransactionErrorCallback&gt;, PassRefPtr&lt;VoidCallback&gt; successCallback);
</span><span class="cx">     void transaction(PassRefPtr&lt;SQLTransactionCallback&gt;, PassRefPtr&lt;SQLTransactionErrorCallback&gt;, PassRefPtr&lt;VoidCallback&gt; successCallback);
</span><span class="cx">     void readTransaction(PassRefPtr&lt;SQLTransactionCallback&gt;, PassRefPtr&lt;SQLTransactionErrorCallback&gt;, PassRefPtr&lt;VoidCallback&gt; successCallback);
</span><span class="cx"> 
</span><span class="cx">     // Internal engine support
</span><ins>+    String stringIdentifier() const;
+    String displayName() const;
+    unsigned long estimatedSize() const;
+    String fileName() const;
+    DatabaseDetails details() const;
+    SQLiteDatabase&amp; sqliteDatabase() { return m_sqliteDatabase; }
+
</ins><span class="cx">     void disableAuthorizer();
</span><span class="cx">     void enableAuthorizer();
</span><span class="cx">     void setAuthorizerPermissions(int);
</span><span class="lines">@@ -112,13 +124,20 @@
</span><span class="cx"> 
</span><span class="cx">     bool getVersionFromDatabase(String&amp; version, bool shouldCacheVersion = true);
</span><span class="cx">     bool setVersionInDatabase(const String&amp; version, bool shouldCacheVersion = true);
</span><ins>+    void setExpectedVersion(const String&amp;);
+    const String&amp; expectedVersion() const { return m_expectedVersion; }
</ins><span class="cx">     String getCachedVersion()const;
</span><span class="cx">     void setCachedVersion(const String&amp;);
</span><ins>+    bool getActualVersionForTransaction(String&amp; version);
</ins><span class="cx"> 
</span><span class="cx">     void scheduleTransaction();
</span><span class="cx"> 
</span><span class="cx">     void runTransaction(RefPtr&lt;SQLTransactionCallback&gt;&amp;&amp;, RefPtr&lt;SQLTransactionErrorCallback&gt;&amp;&amp;, RefPtr&lt;VoidCallback&gt;&amp;&amp; successCallback, bool readOnly, const ChangeVersionData* = nullptr);
</span><span class="cx"> 
</span><ins>+#if !LOG_DISABLED || !ERROR_DISABLED
+    String databaseDebugName() const;
+#endif
+
</ins><span class="cx">     Deque&lt;RefPtr&lt;SQLTransactionBackend&gt;&gt; m_transactionQueue;
</span><span class="cx">     DeprecatedMutex m_transactionInProgressMutex;
</span><span class="cx">     bool m_transactionInProgress;
</span><span class="lines">@@ -137,6 +156,7 @@
</span><span class="cx">     friend class DatabaseServer; // FIXME: remove this when the backend has been split out.
</span><span class="cx">     friend class SQLStatement;
</span><span class="cx">     friend class SQLTransaction;
</span><ins>+    friend class SQLTransactionBackend;
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebdatabaseDatabaseBackendBasecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/webdatabase/DatabaseBackendBase.cpp (188003 => 188004)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/webdatabase/DatabaseBackendBase.cpp        2015-08-05 23:49:51 UTC (rev 188003)
+++ trunk/Source/WebCore/Modules/webdatabase/DatabaseBackendBase.cpp        2015-08-05 23:50:06 UTC (rev 188004)
</span><span class="lines">@@ -80,13 +80,6 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><del>-#if !LOG_DISABLED || !ERROR_DISABLED
-String DatabaseBackendBase::databaseDebugName() const
-{
-    return m_contextThreadSecurityOrigin-&gt;toString() + &quot;::&quot; + m_name;
-}
-#endif
-
</del><span class="cx"> DatabaseBackendBase::DatabaseBackendBase(PassRefPtr&lt;DatabaseContext&gt; databaseContext, const String&amp; name, const String&amp; expectedVersion, const String&amp; displayName, unsigned long estimatedSize)
</span><span class="cx">     : m_databaseContext(databaseContext)
</span><span class="cx">     , m_name(name.isolatedCopy())
</span><span class="lines">@@ -100,76 +93,6 @@
</span><span class="cx"> 
</span><span class="cx"> DatabaseBackendBase::~DatabaseBackendBase()
</span><span class="cx"> {
</span><del>-    // SQLite is &quot;multi-thread safe&quot;, but each database handle can only be used
-    // on a single thread at a time.
-    //
-    // 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
-    // database should have already been closed.
-
-    ASSERT(!m_opened);
</del><span class="cx"> }
</span><span class="cx"> 
</span><del>-String DatabaseBackendBase::version() const
-{
-    // Note: In multi-process browsers the cached value may be accurate, but we cannot read the
-    // actual version from the database without potentially inducing a deadlock.
-    // FIXME: Add an async version getter to the DatabaseAPI.
-    return m_frontend-&gt;getCachedVersion();
-}
-
-SecurityOrigin* DatabaseBackendBase::securityOrigin() const
-{
-    return m_contextThreadSecurityOrigin.get();
-}
-
-String DatabaseBackendBase::stringIdentifier() const
-{
-    // Return a deep copy for ref counting thread safety
-    return m_name.isolatedCopy();
-}
-
-String DatabaseBackendBase::displayName() const
-{
-    // Return a deep copy for ref counting thread safety
-    return m_displayName.isolatedCopy();
-}
-
-unsigned long DatabaseBackendBase::estimatedSize() const
-{
-    return m_estimatedSize;
-}
-
-String DatabaseBackendBase::fileName() const
-{
-    // Return a deep copy for ref counting thread safety
-    return m_filename.isolatedCopy();
-}
-
-DatabaseDetails DatabaseBackendBase::details() const
-{
-    // This code path is only used for database quota delegate calls, so file dates are irrelevant and left uninitialized.
-    return DatabaseDetails(stringIdentifier(), displayName(), estimatedSize(), 0, 0, 0);
-}
-
-void DatabaseBackendBase::setExpectedVersion(const String&amp; version)
-{
-    m_expectedVersion = version.isolatedCopy();
-}
-
-bool DatabaseBackendBase::getActualVersionForTransaction(String &amp;actualVersion)
-{
-    ASSERT(m_sqliteDatabase.transactionInProgress());
-    // Note: In multi-process browsers the cached value may be inaccurate.
-    // So we retrieve the value from the database and update the cached value here.
-    return m_frontend-&gt;getVersionFromDatabase(actualVersion, true);
-}
-
-unsigned long long DatabaseBackendBase::maximumSize() const
-{
-    return DatabaseTracker::tracker().getMaxSizeForDatabase(static_cast&lt;const Database*&gt;(this));
-}
-
</del><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebdatabaseDatabaseBackendBaseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/webdatabase/DatabaseBackendBase.h (188003 => 188004)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/webdatabase/DatabaseBackendBase.h        2015-08-05 23:49:51 UTC (rev 188003)
+++ trunk/Source/WebCore/Modules/webdatabase/DatabaseBackendBase.h        2015-08-05 23:50:06 UTC (rev 188004)
</span><span class="lines">@@ -50,21 +50,7 @@
</span><span class="cx"> public:
</span><span class="cx">     virtual ~DatabaseBackendBase();
</span><span class="cx"> 
</span><del>-    virtual String version() const;
</del><span class="cx"> 
</span><del>-    bool opened() const { return m_opened; }
-    bool isNew() const { return m_new; }
-
-    virtual SecurityOrigin* securityOrigin() const;
-    virtual String stringIdentifier() const;
-    virtual String displayName() const;
-    virtual unsigned long estimatedSize() const;
-    virtual String fileName() const;
-    virtual DatabaseDetails details() const;
-    SQLiteDatabase&amp; sqliteDatabase() { return m_sqliteDatabase; }
-
-    unsigned long long maximumSize() const;
-
</del><span class="cx">     DatabaseContext* databaseContext() const { return m_databaseContext.get(); }
</span><span class="cx">     void setFrontend(Database* frontend) { m_frontend = frontend; }
</span><span class="cx"> 
</span><span class="lines">@@ -77,15 +63,6 @@
</span><span class="cx"> 
</span><span class="cx">     DatabaseBackendBase(PassRefPtr&lt;DatabaseContext&gt;, const String&amp; name, const String&amp; expectedVersion, const String&amp; displayName, unsigned long estimatedSize);
</span><span class="cx"> 
</span><del>-
-    void setExpectedVersion(const String&amp;);
-    const String&amp; expectedVersion() const { return m_expectedVersion; }
-    bool getActualVersionForTransaction(String&amp; version);
-
-#if !LOG_DISABLED || !ERROR_DISABLED
-    String databaseDebugName() const;
-#endif
-
</del><span class="cx">     RefPtr&lt;SecurityOrigin&gt; m_contextThreadSecurityOrigin;
</span><span class="cx">     RefPtr&lt;DatabaseContext&gt; m_databaseContext; // Associated with m_scriptExecutionContext.
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebdatabaseSQLTransactionClientcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/webdatabase/SQLTransactionClient.cpp (188003 => 188004)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/webdatabase/SQLTransactionClient.cpp        2015-08-05 23:49:51 UTC (rev 188003)
+++ trunk/Source/WebCore/Modules/webdatabase/SQLTransactionClient.cpp        2015-08-05 23:50:06 UTC (rev 188004)
</span><span class="lines">@@ -31,7 +31,7 @@
</span><span class="cx"> #include &quot;config.h&quot;
</span><span class="cx"> #include &quot;SQLTransactionClient.h&quot;
</span><span class="cx"> 
</span><del>-#include &quot;DatabaseBackendBase.h&quot;
</del><ins>+#include &quot;Database.h&quot;
</ins><span class="cx"> #include &quot;DatabaseContext.h&quot;
</span><span class="cx"> #include &quot;DatabaseManager.h&quot;
</span><span class="cx"> #include &quot;DatabaseTracker.h&quot;
</span><span class="lines">@@ -40,13 +40,13 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><del>-void SQLTransactionClient::didCommitWriteTransaction(DatabaseBackendBase* database)
</del><ins>+void SQLTransactionClient::didCommitWriteTransaction(Database* database)
</ins><span class="cx"> {
</span><span class="cx">     DatabaseTracker::tracker().scheduleNotifyDatabaseChanged(
</span><span class="cx">         database-&gt;securityOrigin(), database-&gt;stringIdentifier());
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-bool SQLTransactionClient::didExceedQuota(DatabaseBackendBase* database)
</del><ins>+bool SQLTransactionClient::didExceedQuota(Database* database)
</ins><span class="cx"> {
</span><span class="cx">     ASSERT(database-&gt;databaseContext()-&gt;scriptExecutionContext()-&gt;isContextThread());
</span><span class="cx">     auto&amp; databaseManager = DatabaseManager::singleton();
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebdatabaseSQLTransactionClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/webdatabase/SQLTransactionClient.h (188003 => 188004)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/webdatabase/SQLTransactionClient.h        2015-08-05 23:49:51 UTC (rev 188003)
+++ trunk/Source/WebCore/Modules/webdatabase/SQLTransactionClient.h        2015-08-05 23:50:06 UTC (rev 188004)
</span><span class="lines">@@ -36,7 +36,7 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><del>-class DatabaseBackendBase;
</del><ins>+class Database;
</ins><span class="cx"> 
</span><span class="cx"> // A client to the SQLTransaction class. Allows SQLTransaction to notify interested
</span><span class="cx"> // parties that certain things have happened in a transaction.
</span><span class="lines">@@ -44,8 +44,8 @@
</span><span class="cx">     WTF_MAKE_NONCOPYABLE(SQLTransactionClient); WTF_MAKE_FAST_ALLOCATED;
</span><span class="cx"> public:
</span><span class="cx">     SQLTransactionClient() { }
</span><del>-    void didCommitWriteTransaction(DatabaseBackendBase*);
-    bool didExceedQuota(DatabaseBackendBase*);
</del><ins>+    void didCommitWriteTransaction(Database*);
+    bool didExceedQuota(Database*);
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> }
</span></span></pre>
</div>
</div>

</body>
</html>