Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(203)

Side by Side Diff: content/browser/indexed_db/indexed_db_class_factory.h

Issue 2062203004: IDBObserver: Lifetime Management: Adding Observer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Post dmurph review Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_CLASS_FACTORY_H_ 5 #ifndef CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_CLASS_FACTORY_H_
6 #define CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_CLASS_FACTORY_H_ 6 #define CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_CLASS_FACTORY_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
11 #include <set> 11 #include <set>
12 12
13 #include "base/lazy_instance.h" 13 #include "base/lazy_instance.h"
14 #include "content/browser/indexed_db/indexed_db_backing_store.h" 14 #include "content/browser/indexed_db/indexed_db_backing_store.h"
cmumford 2016/06/28 20:26:22 No need to include indexed_db_connection.h. Just f
palakj1 2016/06/29 23:02:40 Done.
15 #include "content/browser/indexed_db/indexed_db_connection.h"
15 #include "content/browser/indexed_db/indexed_db_database.h" 16 #include "content/browser/indexed_db/indexed_db_database.h"
16 #include "content/common/content_export.h" 17 #include "content/common/content_export.h"
17 #include "third_party/WebKit/public/platform/modules/indexeddb/WebIDBTypes.h" 18 #include "third_party/WebKit/public/platform/modules/indexeddb/WebIDBTypes.h"
18 19
19 namespace leveldb { 20 namespace leveldb {
20 class Iterator; 21 class Iterator;
21 } // namespace leveldb 22 } // namespace leveldb
22 23
23 namespace content { 24 namespace content {
24 25
(...skipping 16 matching lines...) Expand all
41 static void SetIndexedDBClassFactoryGetter(GetterCallback* cb); 42 static void SetIndexedDBClassFactoryGetter(GetterCallback* cb);
42 43
43 virtual IndexedDBDatabase* CreateIndexedDBDatabase( 44 virtual IndexedDBDatabase* CreateIndexedDBDatabase(
44 const base::string16& name, 45 const base::string16& name,
45 IndexedDBBackingStore* backing_store, 46 IndexedDBBackingStore* backing_store,
46 IndexedDBFactory* factory, 47 IndexedDBFactory* factory,
47 const IndexedDBDatabase::Identifier& unique_identifier); 48 const IndexedDBDatabase::Identifier& unique_identifier);
48 49
49 virtual IndexedDBTransaction* CreateIndexedDBTransaction( 50 virtual IndexedDBTransaction* CreateIndexedDBTransaction(
50 int64_t id, 51 int64_t id,
52 base::WeakPtr<IndexedDBConnection> connection,
51 scoped_refptr<IndexedDBDatabaseCallbacks> callbacks, 53 scoped_refptr<IndexedDBDatabaseCallbacks> callbacks,
52 const std::set<int64_t>& scope, 54 const std::set<int64_t>& scope,
53 blink::WebIDBTransactionMode mode, 55 blink::WebIDBTransactionMode mode,
54 IndexedDBDatabase* db, 56 IndexedDBDatabase* db,
55 IndexedDBBackingStore::Transaction* backing_store_transaction); 57 IndexedDBBackingStore::Transaction* backing_store_transaction);
56 58
57 virtual LevelDBIteratorImpl* CreateIteratorImpl( 59 virtual LevelDBIteratorImpl* CreateIteratorImpl(
58 std::unique_ptr<leveldb::Iterator> iterator); 60 std::unique_ptr<leveldb::Iterator> iterator);
59 virtual LevelDBTransaction* CreateLevelDBTransaction(LevelDBDatabase* db); 61 virtual LevelDBTransaction* CreateLevelDBTransaction(LevelDBDatabase* db);
60 62
61 protected: 63 protected:
62 IndexedDBClassFactory() {} 64 IndexedDBClassFactory() {}
63 virtual ~IndexedDBClassFactory() {} 65 virtual ~IndexedDBClassFactory() {}
64 friend struct base::DefaultLazyInstanceTraits<IndexedDBClassFactory>; 66 friend struct base::DefaultLazyInstanceTraits<IndexedDBClassFactory>;
65 }; 67 };
66 68
67 } // namespace content 69 } // namespace content
68 70
69 #endif // CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_CLASS_FACTORY_H_ 71 #endif // CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_CLASS_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698