| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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_INDEXED_DB_INDEXED_DB_DATABASE_H_ | 5 #ifndef CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DATABASE_H_ |
| 6 #define CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DATABASE_H_ | 6 #define CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DATABASE_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 190 size_t PendingDeleteCount() const; | 190 size_t PendingDeleteCount() const; |
| 191 | 191 |
| 192 // Asynchronous tasks scheduled within transactions: | 192 // Asynchronous tasks scheduled within transactions: |
| 193 void CreateObjectStoreAbortOperation(int64_t object_store_id, | 193 void CreateObjectStoreAbortOperation(int64_t object_store_id, |
| 194 IndexedDBTransaction* transaction); | 194 IndexedDBTransaction* transaction); |
| 195 void DeleteObjectStoreOperation(int64_t object_store_id, | 195 void DeleteObjectStoreOperation(int64_t object_store_id, |
| 196 IndexedDBTransaction* transaction); | 196 IndexedDBTransaction* transaction); |
| 197 void DeleteObjectStoreAbortOperation( | 197 void DeleteObjectStoreAbortOperation( |
| 198 const IndexedDBObjectStoreMetadata& object_store_metadata, | 198 const IndexedDBObjectStoreMetadata& object_store_metadata, |
| 199 IndexedDBTransaction* transaction); | 199 IndexedDBTransaction* transaction); |
| 200 void VersionChangeOperation(int64_t version, | 200 void VersionChangeOperation( |
| 201 scoped_refptr<IndexedDBCallbacks> callbacks, | 201 const IndexedDBPendingConnection& pending_connection, |
| 202 std::unique_ptr<IndexedDBConnection> connection, | 202 std::unique_ptr<IndexedDBConnection> connection, |
| 203 IndexedDBTransaction* transaction); | 203 IndexedDBTransaction* transaction); |
| 204 void VersionChangeAbortOperation(int64_t previous_version, | 204 void VersionChangeAbortOperation(int64_t previous_version, |
| 205 IndexedDBTransaction* transaction); | 205 IndexedDBTransaction* transaction); |
| 206 void DeleteIndexOperation(int64_t object_store_id, | 206 void DeleteIndexOperation(int64_t object_store_id, |
| 207 int64_t index_id, | 207 int64_t index_id, |
| 208 IndexedDBTransaction* transaction); | 208 IndexedDBTransaction* transaction); |
| 209 void CreateIndexAbortOperation(int64_t object_store_id, | 209 void CreateIndexAbortOperation(int64_t object_store_id, |
| 210 int64_t index_id, | 210 int64_t index_id, |
| 211 IndexedDBTransaction* transaction); | 211 IndexedDBTransaction* transaction); |
| 212 void DeleteIndexAbortOperation(int64_t object_store_id, | 212 void DeleteIndexAbortOperation(int64_t object_store_id, |
| 213 const IndexedDBIndexMetadata& index_metadata, | 213 const IndexedDBIndexMetadata& index_metadata, |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 266 | 266 |
| 267 typedef std::map<int64_t, IndexedDBTransaction*> TransactionMap; | 267 typedef std::map<int64_t, IndexedDBTransaction*> TransactionMap; |
| 268 typedef list_set<IndexedDBConnection*> ConnectionSet; | 268 typedef list_set<IndexedDBConnection*> ConnectionSet; |
| 269 | 269 |
| 270 bool IsUpgradeRunning() const; | 270 bool IsUpgradeRunning() const; |
| 271 bool IsUpgradePendingOrRunning() const; | 271 bool IsUpgradePendingOrRunning() const; |
| 272 | 272 |
| 273 bool IsOpenConnectionBlocked() const; | 273 bool IsOpenConnectionBlocked() const; |
| 274 leveldb::Status OpenInternal(); | 274 leveldb::Status OpenInternal(); |
| 275 void RunVersionChangeTransaction( | 275 void RunVersionChangeTransaction( |
| 276 scoped_refptr<IndexedDBCallbacks> callbacks, | 276 const IndexedDBPendingConnection& pending_connection, |
| 277 std::unique_ptr<IndexedDBConnection> connection, | 277 std::unique_ptr<IndexedDBConnection> connection); |
| 278 int64_t transaction_id, | |
| 279 int64_t requested_version); | |
| 280 void RunVersionChangeTransactionFinal( | 278 void RunVersionChangeTransactionFinal( |
| 281 scoped_refptr<IndexedDBCallbacks> callbacks, | 279 const IndexedDBPendingConnection& pending_connection, |
| 282 std::unique_ptr<IndexedDBConnection> connection, | 280 std::unique_ptr<IndexedDBConnection> connection); |
| 283 int64_t transaction_id, | |
| 284 int64_t requested_version); | |
| 285 void ProcessPendingCalls(); | 281 void ProcessPendingCalls(); |
| 286 | 282 |
| 287 bool IsDeleteDatabaseBlocked() const; | 283 bool IsDeleteDatabaseBlocked() const; |
| 288 void DeleteDatabaseFinal(scoped_refptr<IndexedDBCallbacks> callbacks); | 284 void DeleteDatabaseFinal(scoped_refptr<IndexedDBCallbacks> callbacks); |
| 289 | 285 |
| 290 std::unique_ptr<IndexedDBConnection> CreateConnection( | 286 std::unique_ptr<IndexedDBConnection> CreateConnection( |
| 291 scoped_refptr<IndexedDBDatabaseCallbacks> database_callbacks, | 287 scoped_refptr<IndexedDBDatabaseCallbacks> database_callbacks, |
| 292 int child_process_id); | 288 int child_process_id); |
| 293 | 289 |
| 294 IndexedDBTransaction* GetTransaction(int64_t transaction_id) const; | 290 IndexedDBTransaction* GetTransaction(int64_t transaction_id) const; |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 345 | 341 |
| 346 ConnectionSet connections_; | 342 ConnectionSet connections_; |
| 347 bool experimental_web_platform_features_enabled_; | 343 bool experimental_web_platform_features_enabled_; |
| 348 | 344 |
| 349 DISALLOW_COPY_AND_ASSIGN(IndexedDBDatabase); | 345 DISALLOW_COPY_AND_ASSIGN(IndexedDBDatabase); |
| 350 }; | 346 }; |
| 351 | 347 |
| 352 } // namespace content | 348 } // namespace content |
| 353 | 349 |
| 354 #endif // CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DATABASE_H_ | 350 #endif // CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DATABASE_H_ |
| OLD | NEW |