| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CALLBACKS_H_ | 5 #ifndef CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CALLBACKS_H_ |
| 6 #define CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CALLBACKS_H_ | 6 #define CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CALLBACKS_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "content/browser/in_process_webkit/indexed_db_dispatcher_host.h" | 10 #include "content/browser/in_process_webkit/indexed_db_dispatcher_host.h" |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 | 24 |
| 25 virtual void onError(const WebKit::WebIDBDatabaseError& error); | 25 virtual void onError(const WebKit::WebIDBDatabaseError& error); |
| 26 virtual void onBlocked(long long old_version); | 26 virtual void onBlocked(long long old_version); |
| 27 | 27 |
| 28 // implemented by subclasses, but need to be called later | 28 // implemented by subclasses, but need to be called later |
| 29 virtual void onSuccess(const std::vector<string16>& value); | 29 virtual void onSuccess(const std::vector<string16>& value); |
| 30 virtual void onSuccess(WebIDBDatabaseImpl* idb_object, | 30 virtual void onSuccess(WebIDBDatabaseImpl* idb_object, |
| 31 const IndexedDBDatabaseMetadata& metadata); | 31 const IndexedDBDatabaseMetadata& metadata); |
| 32 virtual void onUpgradeNeeded(long long old_version, | 32 virtual void onUpgradeNeeded(long long old_version, |
| 33 WebIDBDatabaseImpl* database, | 33 WebIDBDatabaseImpl* database, |
| 34 const IndexedDBDatabaseMetadata&); | 34 const IndexedDBDatabaseMetadata&, |
| 35 bool data_loss); |
| 35 virtual void onSuccess(WebIDBCursorImpl* idb_object, | 36 virtual void onSuccess(WebIDBCursorImpl* idb_object, |
| 36 const IndexedDBKey& key, | 37 const IndexedDBKey& key, |
| 37 const IndexedDBKey& primaryKey, | 38 const IndexedDBKey& primaryKey, |
| 38 std::vector<char>* value); | 39 std::vector<char>* value); |
| 39 virtual void onSuccess(const IndexedDBKey& key, | 40 virtual void onSuccess(const IndexedDBKey& key, |
| 40 const IndexedDBKey& primaryKey, | 41 const IndexedDBKey& primaryKey, |
| 41 std::vector<char>* value); | 42 std::vector<char>* value); |
| 42 virtual void onSuccess(std::vector<char>* value); | 43 virtual void onSuccess(std::vector<char>* value); |
| 43 virtual void onSuccessWithPrefetch( | 44 virtual void onSuccessWithPrefetch( |
| 44 const std::vector<IndexedDBKey>& keys, | 45 const std::vector<IndexedDBKey>& keys, |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 82 int32 ipc_thread_id, | 83 int32 ipc_thread_id, |
| 83 int32 ipc_callbacks_id, | 84 int32 ipc_callbacks_id, |
| 84 int32 ipc_database_callbacks_id, | 85 int32 ipc_database_callbacks_id, |
| 85 int64 host_transaction_id, | 86 int64 host_transaction_id, |
| 86 const GURL& origin_url); | 87 const GURL& origin_url); |
| 87 | 88 |
| 88 virtual void onSuccess(WebIDBDatabaseImpl* idb_object, | 89 virtual void onSuccess(WebIDBDatabaseImpl* idb_object, |
| 89 const IndexedDBDatabaseMetadata& metadata) OVERRIDE; | 90 const IndexedDBDatabaseMetadata& metadata) OVERRIDE; |
| 90 virtual void onUpgradeNeeded(long long old_version, | 91 virtual void onUpgradeNeeded(long long old_version, |
| 91 WebIDBDatabaseImpl* database, | 92 WebIDBDatabaseImpl* database, |
| 92 const IndexedDBDatabaseMetadata&) OVERRIDE; | 93 const IndexedDBDatabaseMetadata&, |
| 94 bool data_loss) OVERRIDE; |
| 93 | 95 |
| 94 private: | 96 private: |
| 95 int64 host_transaction_id_; | 97 int64 host_transaction_id_; |
| 96 GURL origin_url_; | 98 GURL origin_url_; |
| 97 int32 ipc_database_id_; | 99 int32 ipc_database_id_; |
| 98 int32 ipc_database_callbacks_id_; | 100 int32 ipc_database_callbacks_id_; |
| 99 DISALLOW_IMPLICIT_CONSTRUCTORS(IndexedDBCallbacksDatabase); | 101 DISALLOW_IMPLICIT_CONSTRUCTORS(IndexedDBCallbacksDatabase); |
| 100 }; | 102 }; |
| 101 | 103 |
| 102 // WebIDBCursorImpl uses: | 104 // WebIDBCursorImpl uses: |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 virtual void onSuccess(); | 199 virtual void onSuccess(); |
| 198 virtual void onSuccess(const IndexedDBKey& value); | 200 virtual void onSuccess(const IndexedDBKey& value); |
| 199 | 201 |
| 200 private: | 202 private: |
| 201 DISALLOW_IMPLICIT_CONSTRUCTORS(IndexedDBCallbacks); | 203 DISALLOW_IMPLICIT_CONSTRUCTORS(IndexedDBCallbacks); |
| 202 }; | 204 }; |
| 203 | 205 |
| 204 } // namespace content | 206 } // namespace content |
| 205 | 207 |
| 206 #endif // CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CALLBACKS_H_ | 208 #endif // CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CALLBACKS_H_ |
| OLD | NEW |