Chromium Code Reviews| Index: content/browser/indexed_db/indexed_db_database.h |
| diff --git a/content/browser/indexed_db/indexed_db_database.h b/content/browser/indexed_db/indexed_db_database.h |
| index 72d65ce723e985a331cdd2c3e286af32d2ade7c3..7b1c287d77fff25ead58686adaee99904e42c24e 100644 |
| --- a/content/browser/indexed_db/indexed_db_database.h |
| +++ b/content/browser/indexed_db/indexed_db_database.h |
| @@ -38,6 +38,7 @@ class IndexedDBFactory; |
| class IndexedDBKey; |
| class IndexedDBKeyPath; |
| class IndexedDBKeyRange; |
| +class IndexedDBObserver; |
| class IndexedDBTransaction; |
| struct IndexedDBValue; |
| @@ -50,6 +51,8 @@ class CONTENT_EXPORT IndexedDBDatabase |
| // Identifier is pair of (origin, database name). |
| using Identifier = std::pair<url::Origin, base::string16>; |
| + std::map<int64_t, IndexedDBObserver*> active_observers_; |
|
dmurph
2016/06/17 09:05:06
wrap IndexedDBObserver with std::unique_ptr
palakj1
2016/06/18 05:13:40
Done
|
| + |
| static const int64_t kInvalidId = 0; |
| static const int64_t kMinimumIndexId = 30; |
| @@ -124,6 +127,9 @@ class CONTENT_EXPORT IndexedDBDatabase |
| // Called by transactions to report failure committing to the backing store. |
| void TransactionCommitFailed(const leveldb::Status& status); |
| + void Observe(int64_t transaction_id, int64_t observer_id); |
| + void Unobserve(std::vector<int64_t> observersToRemove); |
| + |
| void Get(int64_t transaction_id, |
| int64_t object_store_id, |
| int64_t index_id, |