https://bugs.webkit.org/show_bug.cgi?id=89893
Reviewed by Darin Fisher.
Source/WebCore:
Following the "metadata" API addition in trac.webkit.org/changeset/121059
the IDBXXXBackendInterface types no longer need per-property accessors.
No new tests - no functional changes.
* Modules/indexeddb/IDBDatabaseBackendImpl.cpp: Remove method implementation.
* Modules/indexeddb/IDBDatabaseBackendImpl.h: Remove methods.
(IDBDatabaseBackendImpl):
* Modules/indexeddb/IDBDatabaseBackendInterface.h: Remove methods.
(IDBDatabaseBackendInterface):
* Modules/indexeddb/IDBIndexBackendImpl.h: Make methods simple accessors.
(IDBIndexBackendImpl):
(WebCore::IDBIndexBackendImpl::name):
(WebCore::IDBIndexBackendImpl::keyPath):
(WebCore::IDBIndexBackendImpl::unique):
(WebCore::IDBIndexBackendImpl::multiEntry):
* Modules/indexeddb/IDBIndexBackendInterface.h: Remove methods.
* Modules/indexeddb/IDBObjectStoreBackendImpl.cpp: Remove method implementation.
* Modules/indexeddb/IDBObjectStoreBackendImpl.h: Make methods simple accessors.
(IDBObjectStoreBackendImpl):
(WebCore::IDBObjectStoreBackendImpl::name):
(WebCore::IDBObjectStoreBackendImpl::keyPath):
(WebCore::IDBObjectStoreBackendImpl::autoIncrement):
* Modules/indexeddb/IDBObjectStoreBackendInterface.h: Remove methods.
Source/WebKit/chromium:
Following the "metadata" API addition in trac.webkit.org/changeset/121059
per-property accessors can be removed from the Chromium WebKit API.
* src/WebIDBDatabaseImpl.cpp: Removed name, version, objectStoreNames.
* src/WebIDBDatabaseImpl.h:
(WebIDBDatabaseImpl):
* src/WebIDBIndexImpl.cpp: Removed name, keyPath, unique, multiEntry.
* src/WebIDBIndexImpl.h:
(WebIDBIndexImpl):
* src/WebIDBObjectStoreImpl.cpp: Removed name, keyPath, autoIncrement, indexNames.
* src/WebIDBObjectStoreImpl.h:
(WebIDBObjectStoreImpl):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@121183
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2012-06-25 Joshua Bell <jsbell@chromium.org>
+
+ IndexedDB: Remove unused backend property accessors
+ https://bugs.webkit.org/show_bug.cgi?id=89893
+
+ Reviewed by Darin Fisher.
+
+ Following the "metadata" API addition in trac.webkit.org/changeset/121059
+ the IDBXXXBackendInterface types no longer need per-property accessors.
+
+ No new tests - no functional changes.
+
+ * Modules/indexeddb/IDBDatabaseBackendImpl.cpp: Remove method implementation.
+ * Modules/indexeddb/IDBDatabaseBackendImpl.h: Remove methods.
+ (IDBDatabaseBackendImpl):
+ * Modules/indexeddb/IDBDatabaseBackendInterface.h: Remove methods.
+ (IDBDatabaseBackendInterface):
+ * Modules/indexeddb/IDBIndexBackendImpl.h: Make methods simple accessors.
+ (IDBIndexBackendImpl):
+ (WebCore::IDBIndexBackendImpl::name):
+ (WebCore::IDBIndexBackendImpl::keyPath):
+ (WebCore::IDBIndexBackendImpl::unique):
+ (WebCore::IDBIndexBackendImpl::multiEntry):
+ * Modules/indexeddb/IDBIndexBackendInterface.h: Remove methods.
+ * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp: Remove method implementation.
+ * Modules/indexeddb/IDBObjectStoreBackendImpl.h: Make methods simple accessors.
+ (IDBObjectStoreBackendImpl):
+ (WebCore::IDBObjectStoreBackendImpl::name):
+ (WebCore::IDBObjectStoreBackendImpl::keyPath):
+ (WebCore::IDBObjectStoreBackendImpl::autoIncrement):
+ * Modules/indexeddb/IDBObjectStoreBackendInterface.h: Remove methods.
+
2012-06-25 Sudarsana Nagineni <sudarsana.nagineni@linux.intel.com>
[EFL] Add support for building with ENABLE_MEDIA_STREAM
return metadata;
}
-PassRefPtr<DOMStringList> IDBDatabaseBackendImpl::objectStoreNames() const
-{
- RefPtr<DOMStringList> objectStoreNames = DOMStringList::create();
- for (ObjectStoreMap::const_iterator it = m_objectStores.begin(); it != m_objectStores.end(); ++it)
- objectStoreNames->append(it->first);
- objectStoreNames->sort();
- return objectStoreNames.release();
-}
-
PassRefPtr<IDBObjectStoreBackendInterface> IDBDatabaseBackendImpl::createObjectStore(const String& name, const IDBKeyPath& keyPath, bool autoIncrement, IDBTransactionBackendInterface* transactionPtr, ExceptionCode& ec)
{
ASSERT(transactionPtr->mode() == IDBTransaction::VERSION_CHANGE);
void deleteDatabase(PassRefPtr<IDBCallbacks>);
virtual IDBDatabaseMetadata metadata() const;
- virtual String name() const { return m_name; }
- virtual String version() const { return m_version; }
- virtual PassRefPtr<DOMStringList> objectStoreNames() const;
virtual PassRefPtr<IDBObjectStoreBackendInterface> createObjectStore(const String& name, const IDBKeyPath&, bool autoIncrement, IDBTransactionBackendInterface*, ExceptionCode&);
virtual void deleteObjectStore(const String& name, IDBTransactionBackendInterface*, ExceptionCode&);
virtual ~IDBDatabaseBackendInterface() { }
virtual IDBDatabaseMetadata metadata() const = 0;
- virtual String name() const = 0;
- virtual String version() const = 0;
- virtual PassRefPtr<DOMStringList> objectStoreNames() const = 0;
virtual PassRefPtr<IDBObjectStoreBackendInterface> createObjectStore(const String& name, const IDBKeyPath&, bool autoIncrement, IDBTransactionBackendInterface*, ExceptionCode&) = 0;
virtual void deleteObjectStore(const String& name, IDBTransactionBackendInterface*, ExceptionCode&) = 0;
// Implements IDBIndexBackendInterface.
virtual IDBIndexMetadata metadata() const;
- virtual String name() { return m_name; }
- virtual IDBKeyPath keyPath() { return m_keyPath; }
- virtual bool unique() { return m_unique; }
- virtual bool multiEntry() { return m_multiEntry; }
virtual void openCursor(PassRefPtr<IDBKeyRange>, unsigned short direction, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&);
virtual void count(PassRefPtr<IDBKeyRange>, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&);
virtual void get(PassRefPtr<IDBKeyRange>, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&);
virtual void getKey(PassRefPtr<IDBKeyRange>, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&);
+ const String& name() { return m_name; }
+ const IDBKeyPath& keyPath() { return m_keyPath; }
+ const bool& unique() { return m_unique; }
+ const bool& multiEntry() { return m_multiEntry; }
+
private:
IDBIndexBackendImpl(const IDBDatabaseBackendImpl*, IDBObjectStoreBackendImpl*, int64_t id, const String& name, const IDBKeyPath&, bool unique, bool multiEntry);
IDBIndexBackendImpl(const IDBDatabaseBackendImpl*, IDBObjectStoreBackendImpl*, const String& name, const IDBKeyPath&, bool unique, bool multiEntry);
public:
virtual ~IDBIndexBackendInterface() { }
- virtual String name() = 0;
- virtual IDBKeyPath keyPath() = 0;
- virtual bool unique() = 0;
- virtual bool multiEntry() = 0;
-
virtual void openCursor(PassRefPtr<IDBKeyRange>, unsigned short direction, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&) = 0;
virtual void count(PassRefPtr<IDBKeyRange>, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&) = 0;
virtual void openKeyCursor(PassRefPtr<IDBKeyRange>, unsigned short direction, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&) = 0;
return metadata;
}
-PassRefPtr<DOMStringList> IDBObjectStoreBackendImpl::indexNames() const
-{
- RefPtr<DOMStringList> indexNames = DOMStringList::create();
- for (IndexMap::const_iterator it = m_indexes.begin(); it != m_indexes.end(); ++it)
- indexNames->append(it->first);
- indexNames->sort();
- return indexNames.release();
-}
-
void IDBObjectStoreBackendImpl::get(PassRefPtr<IDBKeyRange> prpKeyRange, PassRefPtr<IDBCallbacks> prpCallbacks, IDBTransactionBackendInterface* transaction, ExceptionCode& ec)
{
IDB_TRACE("IDBObjectStoreBackendImpl::get");
void setId(int64_t id) { m_id = id; }
virtual IDBObjectStoreMetadata metadata() const;
- virtual String name() const { return m_name; }
- virtual IDBKeyPath keyPath() const { return m_keyPath; }
- virtual PassRefPtr<DOMStringList> indexNames() const;
- virtual bool autoIncrement() const { return m_autoIncrement; }
virtual void get(PassRefPtr<IDBKeyRange>, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&);
virtual void put(PassRefPtr<SerializedScriptValue>, PassRefPtr<IDBKey>, PutMode, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&);
static bool populateIndex(IDBBackingStore&, int64_t databaseId, int64_t objectStoreId, PassRefPtr<IDBIndexBackendImpl>);
+ const String& name() { return m_name; }
+ const IDBKeyPath& keyPath() const { return m_keyPath; }
+ const bool& autoIncrement() const { return m_autoIncrement; }
+
private:
IDBObjectStoreBackendImpl(const IDBDatabaseBackendImpl*, int64_t databaseId, const String& name, const IDBKeyPath&, bool autoIncrement);
IDBObjectStoreBackendImpl(const IDBDatabaseBackendImpl*, const String& name, const IDBKeyPath&, bool autoIncrement);
public:
virtual ~IDBObjectStoreBackendInterface() { }
- virtual String name() const = 0;
- virtual IDBKeyPath keyPath() const = 0;
- virtual PassRefPtr<DOMStringList> indexNames() const = 0;
- virtual bool autoIncrement() const = 0;
-
virtual void get(PassRefPtr<IDBKeyRange>, PassRefPtr<IDBCallbacks>, IDBTransactionBackendInterface*, ExceptionCode&) = 0;
enum PutMode {
+2012-06-25 Joshua Bell <jsbell@chromium.org>
+
+ IndexedDB: Remove unused backend property accessors
+ https://bugs.webkit.org/show_bug.cgi?id=89893
+
+ Reviewed by Darin Fisher.
+
+ Following the "metadata" API addition in trac.webkit.org/changeset/121059
+ per-property accessors can be removed from the Chromium WebKit API.
+
+ * src/WebIDBDatabaseImpl.cpp: Removed name, version, objectStoreNames.
+ * src/WebIDBDatabaseImpl.h:
+ (WebIDBDatabaseImpl):
+ * src/WebIDBIndexImpl.cpp: Removed name, keyPath, unique, multiEntry.
+ * src/WebIDBIndexImpl.h:
+ (WebIDBIndexImpl):
+ * src/WebIDBObjectStoreImpl.cpp: Removed name, keyPath, autoIncrement, indexNames.
+ * src/WebIDBObjectStoreImpl.h:
+ (WebIDBObjectStoreImpl):
+
2012-06-25 Ian Vollick <vollick@chromium.org>
[chromium] Layer chromium should need a redraw after getting its first non-empty bounds.
return m_databaseBackend->metadata();
}
-WebString WebIDBDatabaseImpl::name() const
-{
- return m_databaseBackend->name();
-}
-
-WebString WebIDBDatabaseImpl::version() const
-{
- return m_databaseBackend->version();
-}
-
-WebDOMStringList WebIDBDatabaseImpl::objectStoreNames() const
-{
- return m_databaseBackend->objectStoreNames();
-}
-
WebIDBObjectStore* WebIDBDatabaseImpl::createObjectStore(const WebString& name, const WebIDBKeyPath& keyPath, bool autoIncrement, const WebIDBTransaction& transaction, WebExceptionCode& ec)
{
RefPtr<IDBObjectStoreBackendInterface> objectStore = m_databaseBackend->createObjectStore(name, keyPath, autoIncrement, transaction.getIDBTransactionBackendInterface(), ec);
virtual ~WebIDBDatabaseImpl();
virtual WebIDBMetadata metadata() const;
- virtual WebString name() const;
- virtual WebString version() const;
- virtual WebDOMStringList objectStoreNames() const;
virtual WebIDBObjectStore* createObjectStore(const WebString& name, const WebIDBKeyPath&, bool autoIncrement, const WebIDBTransaction&, WebExceptionCode&);
virtual void deleteObjectStore(const WebString& name, const WebIDBTransaction&, WebExceptionCode&);
{
}
-WebString WebIDBIndexImpl::name() const
-{
- return m_backend->name();
-}
-
-WebIDBKeyPath WebIDBIndexImpl::keyPath() const
-{
- return WebIDBKeyPath(m_backend->keyPath());
-}
-
-bool WebIDBIndexImpl::unique() const
-{
- return m_backend->unique();
-}
-
-bool WebIDBIndexImpl::multiEntry() const
-{
- return m_backend->multiEntry();
-}
-
void WebIDBIndexImpl::openObjectCursor(const WebIDBKeyRange& keyRange, unsigned short direction, WebIDBCallbacks* callbacks, const WebIDBTransaction& transaction, WebExceptionCode& ec)
{
m_backend->openCursor(keyRange, direction, IDBCallbacksProxy::create(adoptPtr(callbacks)), transaction.getIDBTransactionBackendInterface(), ec);
WebIDBIndexImpl(WTF::PassRefPtr<WebCore::IDBIndexBackendInterface>);
virtual ~WebIDBIndexImpl();
- virtual WebString name() const;
- virtual WebIDBKeyPath keyPath() const;
- virtual bool unique() const;
- virtual bool multiEntry() const;
-
virtual void openObjectCursor(const WebIDBKeyRange&, unsigned short direction, WebIDBCallbacks*, const WebIDBTransaction&, WebExceptionCode&);
virtual void openKeyCursor(const WebIDBKeyRange&, unsigned short direction, WebIDBCallbacks*, const WebIDBTransaction&, WebExceptionCode&);
virtual void count(const WebIDBKeyRange&, WebIDBCallbacks*, const WebIDBTransaction&, WebExceptionCode&);
{
}
-WebString WebIDBObjectStoreImpl::name() const
-{
- return m_objectStore->name();
-}
-
-WebIDBKeyPath WebIDBObjectStoreImpl::keyPath() const
-{
- return m_objectStore->keyPath();
-}
-
-WebDOMStringList WebIDBObjectStoreImpl::indexNames() const
-{
- return m_objectStore->indexNames();
-}
-
-bool WebIDBObjectStoreImpl::autoIncrement() const
-{
- return m_objectStore->autoIncrement();
-}
-
void WebIDBObjectStoreImpl::get(const WebIDBKeyRange& keyRange, WebIDBCallbacks* callbacks, const WebIDBTransaction& transaction, WebExceptionCode& ec)
{
m_objectStore->get(keyRange, IDBCallbacksProxy::create(adoptPtr(callbacks)), transaction.getIDBTransactionBackendInterface(), ec);
WebIDBObjectStoreImpl(WTF::PassRefPtr<WebCore::IDBObjectStoreBackendInterface>);
~WebIDBObjectStoreImpl();
- WebString name() const;
- WebIDBKeyPath keyPath() const;
- WebDOMStringList indexNames() const;
- bool autoIncrement() const;
-
void get(const WebIDBKeyRange&, WebIDBCallbacks*, const WebIDBTransaction&, WebExceptionCode&);
void put(const WebSerializedScriptValue&, const WebIDBKey&, PutMode, WebIDBCallbacks*, const WebIDBTransaction&, WebExceptionCode&);
void deleteFunction(const WebIDBKeyRange&, WebIDBCallbacks*, const WebIDBTransaction&, WebExceptionCode&);