Changeset 138963 in webkit


Ignore:
Timestamp:
Jan 7, 2013 10:53:47 AM (11 years ago)
Author:
alecflett@chromium.org
Message:

IndexedDB: Stub out async IDBDatabaseBackendInterface::createObjectStore
https://bugs.webkit.org/show_bug.cgi?id=106148

Reviewed by Adam Barth.

Source/WebCore:

These methods are becoming async in multiprocess ports, so stub out
versions that have no return values.

  • Modules/indexeddb/IDBDatabaseBackendImpl.h:

(WebCore::IDBDatabaseBackendImpl::createObjectStore):
(WebCore::IDBDatabaseBackendImpl::deleteObjectStore):

  • Modules/indexeddb/IDBDatabaseBackendInterface.h:

(IDBDatabaseBackendInterface):

Source/WebKit/chromium:

Stub out WebKit API for async createObjectStore.

  • public/WebIDBDatabase.h:

(WebIDBDatabase):

  • src/IDBDatabaseBackendProxy.cpp:

(WebKit::IDBDatabaseBackendProxy::createObjectStore):
(WebKit):
(WebKit::IDBDatabaseBackendProxy::deleteObjectStore):

  • src/IDBDatabaseBackendProxy.h:

(IDBDatabaseBackendProxy):

  • src/WebIDBDatabaseImpl.cpp:

(WebKit::WebIDBDatabaseImpl::createObjectStore):
(WebKit):
(WebKit::WebIDBDatabaseImpl::deleteObjectStore):

  • src/WebIDBDatabaseImpl.h:

(WebIDBDatabaseImpl):

Location:
trunk/Source
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r138962 r138963  
     12013-01-07  Alec Flett  <alecflett@chromium.org>
     2
     3        IndexedDB: Stub out async IDBDatabaseBackendInterface::createObjectStore
     4        https://bugs.webkit.org/show_bug.cgi?id=106148
     5
     6        Reviewed by Adam Barth.
     7
     8        These methods are becoming async in multiprocess ports, so stub out
     9        versions that have no return values.
     10
     11        * Modules/indexeddb/IDBDatabaseBackendImpl.h:
     12        (WebCore::IDBDatabaseBackendImpl::createObjectStore):
     13        (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
     14        * Modules/indexeddb/IDBDatabaseBackendInterface.h:
     15        (IDBDatabaseBackendInterface):
     16
    1172013-01-04  Alexey Proskuryakov  <ap@apple.com>
    218
  • trunk/Source/WebCore/Modules/indexeddb/IDBDatabaseBackendImpl.h

    r138898 r138963  
    6262    virtual IDBDatabaseMetadata metadata() const;
    6363    virtual PassRefPtr<IDBObjectStoreBackendInterface> createObjectStore(int64_t id, const String& name, const IDBKeyPath&, bool autoIncrement, IDBTransactionBackendInterface*, ExceptionCode&);
     64    virtual void createObjectStore(int64_t transactionId, int64_t objectStoreId, const String& name, const IDBKeyPath&, bool autoIncrement) { ASSERT_NOT_REACHED(); }
    6465    virtual void deleteObjectStore(int64_t, IDBTransactionBackendInterface*, ExceptionCode&);
     66    virtual void deleteObjectStore(int64_t transactionId, int64_t objectStoreId) { ASSERT_NOT_REACHED(); }
    6567    // FIXME: Remove this method in https://bugs.webkit.org/show_bug.cgi?id=103923.
    6668    virtual PassRefPtr<IDBTransactionBackendInterface> createTransaction(int64_t transactionId, const Vector<int64_t>& objectStoreIds, IDBTransaction::Mode);
  • trunk/Source/WebCore/Modules/indexeddb/IDBDatabaseBackendInterface.h

    r138898 r138963  
    5757
    5858    virtual PassRefPtr<IDBObjectStoreBackendInterface> createObjectStore(int64_t, const String& name, const IDBKeyPath&, bool autoIncrement, IDBTransactionBackendInterface*, ExceptionCode&) = 0;
     59    virtual void createObjectStore(int64_t transactionId, int64_t objectStoreId, const String& name, const IDBKeyPath&, bool autoIncrement) = 0;
    5960    virtual void deleteObjectStore(int64_t, IDBTransactionBackendInterface*, ExceptionCode&) = 0;
     61    virtual void deleteObjectStore(int64_t transactionId, int64_t objectStoreId) = 0;
    6062    // FIXME: Remove this method in https://bugs.webkit.org/show_bug.cgi?id=103923.
    6163    virtual PassRefPtr<IDBTransactionBackendInterface> createTransaction(int64_t transactionId, const Vector<int64_t>& objectStoreIds, IDBTransaction::Mode) = 0;
  • trunk/Source/WebKit/chromium/ChangeLog

    r138950 r138963  
     12013-01-07  Alec Flett  <alecflett@chromium.org>
     2
     3        IndexedDB: Stub out async IDBDatabaseBackendInterface::createObjectStore
     4        https://bugs.webkit.org/show_bug.cgi?id=106148
     5
     6        Reviewed by Adam Barth.
     7
     8        Stub out WebKit API for async createObjectStore.
     9
     10        * public/WebIDBDatabase.h:
     11        (WebIDBDatabase):
     12        * src/IDBDatabaseBackendProxy.cpp:
     13        (WebKit::IDBDatabaseBackendProxy::createObjectStore):
     14        (WebKit):
     15        (WebKit::IDBDatabaseBackendProxy::deleteObjectStore):
     16        * src/IDBDatabaseBackendProxy.h:
     17        (IDBDatabaseBackendProxy):
     18        * src/WebIDBDatabaseImpl.cpp:
     19        (WebKit::WebIDBDatabaseImpl::createObjectStore):
     20        (WebKit):
     21        (WebKit::WebIDBDatabaseImpl::deleteObjectStore):
     22        * src/WebIDBDatabaseImpl.h:
     23        (WebIDBDatabaseImpl):
     24
    1252013-01-07  Stephen Chenney  <schenney@chromium.org>
    226
  • trunk/Source/WebKit/chromium/public/WebIDBDatabase.h

    r138900 r138963  
    5959        return 0;
    6060    }
     61    virtual void createObjectStore(long long transactionId, long long objectStoreId, const WebString& name, const WebIDBKeyPath&, bool autoIncrement) { WEBKIT_ASSERT_NOT_REACHED(); }
    6162    virtual void deleteObjectStore(long long objectStoreId, const WebIDBTransaction& transaction, WebExceptionCode& ec) { WEBKIT_ASSERT_NOT_REACHED(); }
     63    virtual void deleteObjectStore(long long transactionId, long long objectStoreId) { WEBKIT_ASSERT_NOT_REACHED(); }
    6264    // FIXME: Remove this method in https://bugs.webkit.org/show_bug.cgi?id=103923.
    6365    virtual WebIDBTransaction* createTransaction(long long id, const WebVector<long long>&, unsigned short mode) { WEBKIT_ASSERT_NOT_REACHED(); return 0; }
  • trunk/Source/WebKit/chromium/src/IDBDatabaseBackendProxy.cpp

    r138898 r138963  
    8080}
    8181
     82void IDBDatabaseBackendProxy::createObjectStore(int64_t transactionId, int64_t objectStoreId, const String& name, const IDBKeyPath& keyPath, bool autoIncrement)
     83{
     84    if (m_webIDBDatabase)
     85        m_webIDBDatabase->createObjectStore(transactionId, objectStoreId, name, keyPath, autoIncrement);
     86}
     87
    8288void IDBDatabaseBackendProxy::deleteObjectStore(int64_t objectStoreId, IDBTransactionBackendInterface* transaction, ExceptionCode& ec)
    8389{
     
    8692    IDBTransactionBackendProxy* transactionProxy = static_cast<IDBTransactionBackendProxy*>(transaction);
    8793    m_webIDBDatabase->deleteObjectStore(objectStoreId, *transactionProxy->getWebIDBTransaction(), ec);
     94}
     95
     96void IDBDatabaseBackendProxy::deleteObjectStore(int64_t transactionId, int64_t objectStoreId)
     97{
     98    if (m_webIDBDatabase)
     99        m_webIDBDatabase->deleteObjectStore(transactionId, objectStoreId);
    88100}
    89101
  • trunk/Source/WebKit/chromium/src/IDBDatabaseBackendProxy.h

    r138898 r138963  
    4646
    4747    virtual PassRefPtr<WebCore::IDBObjectStoreBackendInterface> createObjectStore(int64_t, const String& name, const WebCore::IDBKeyPath&, bool autoIncrement, WebCore::IDBTransactionBackendInterface*, WebCore::ExceptionCode&);
     48    virtual void createObjectStore(int64_t transactionId, int64_t objectStoreId, const String& name, const WebCore::IDBKeyPath&, bool autoIncrement);
    4849    virtual void deleteObjectStore(int64_t, WebCore::IDBTransactionBackendInterface*, WebCore::ExceptionCode&);
     50    virtual void deleteObjectStore(int64_t transactionId, int64_t objectStoreId);
    4951    // FIXME: Remove this method in https://bugs.webkit.org/show_bug.cgi?id=103923.
    5052    virtual PassRefPtr<WebCore::IDBTransactionBackendInterface> createTransaction(int64_t, const Vector<int64_t>&, WebCore::IDBTransaction::Mode);
  • trunk/Source/WebKit/chromium/src/WebIDBDatabaseImpl.cpp

    r138900 r138963  
    7373}
    7474
     75void WebIDBDatabaseImpl::createObjectStore(long long transactionId, long long objectStoreId, const WebString& name, const WebIDBKeyPath& keyPath, bool autoIncrement)
     76{
     77    m_databaseBackend->createObjectStore(transactionId, objectStoreId, name, keyPath, autoIncrement);
     78}
     79
    7580void WebIDBDatabaseImpl::deleteObjectStore(long long objectStoreId, const WebIDBTransaction& transaction, WebExceptionCode& ec)
    7681{
    7782    m_databaseBackend->deleteObjectStore(objectStoreId, transaction.getIDBTransactionBackendInterface(), ec);
    7883}
     84
     85void WebIDBDatabaseImpl::deleteObjectStore(long long transactionId, long long objectStoreId)
     86{
     87    m_databaseBackend->deleteObjectStore(transactionId, objectStoreId);
     88}
     89
    7990
    8091// FIXME: Remove this method in https://bugs.webkit.org/show_bug.cgi?id=103923.
  • trunk/Source/WebKit/chromium/src/WebIDBDatabaseImpl.h

    r138898 r138963  
    5555
    5656    virtual WebIDBObjectStore* createObjectStore(long long, const WebString& name, const WebIDBKeyPath&, bool autoIncrement, const WebIDBTransaction&, WebExceptionCode&);
     57    virtual void createObjectStore(long long transactionId, long long objectStoreId, const WebString& name, const WebIDBKeyPath&, bool autoIncrement);
    5758    virtual void deleteObjectStore(long long objectStoreId, const WebIDBTransaction&, WebExceptionCode&);
     59    virtual void deleteObjectStore(long long objectStoreId, long long transactionId);
    5860    // FIXME: Remove this method in https://bugs.webkit.org/show_bug.cgi?id=103923.
    5961    virtual WebIDBTransaction* createTransaction(long long id, const WebVector<long long>&, unsigned short mode);
  • trunk/Source/WebKit/chromium/tests/IDBDatabaseBackendTest.cpp

    r138900 r138963  
    152152
    153153    virtual IDBDatabaseMetadata metadata() const { return IDBDatabaseMetadata(); }
    154     virtual PassRefPtr<IDBObjectStoreBackendInterface> createObjectStore(int64_t, const String& name, const IDBKeyPath&, bool autoIncrement, IDBTransactionBackendInterface*, ExceptionCode&) { return 0; }
    155     virtual void deleteObjectStore(const String& name, IDBTransactionBackendInterface*, ExceptionCode&) { }
    156     virtual void deleteObjectStore(int64_t, IDBTransactionBackendInterface*, ExceptionCode&) { }
     154    virtual PassRefPtr<IDBObjectStoreBackendInterface> createObjectStore(int64_t, const String& name, const IDBKeyPath&, bool autoIncrement, IDBTransactionBackendInterface*, ExceptionCode&) OVERRIDE { return 0; }
     155    virtual void createObjectStore(int64_t transactionId, int64_t objectStoreId, const String& name, const IDBKeyPath&, bool autoIncrement) OVERRIDE { };
     156    virtual void deleteObjectStore(int64_t transactionId, int64_t objectStoreId) OVERRIDE { }
     157    virtual void deleteObjectStore(int64_t, IDBTransactionBackendInterface*, ExceptionCode&) OVERRIDE { }
    157158    // FIXME: Remove this method in https://bugs.webkit.org/show_bug.cgi?id=103923.
    158159    virtual PassRefPtr<IDBTransactionBackendInterface> createTransaction(int64_t, const Vector<int64_t>&, IDBTransaction::Mode) OVERRIDE { return 0; }
Note: See TracChangeset for help on using the changeset viewer.