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

Side by Side Diff: content/browser/in_process_webkit/indexed_db_context.h

Issue 7053030: Initial IndexedDBQuotaClient implementation (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: make webkit thread outlive IndexedDBContext Created 9 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « chrome/test/testing_profile.cc ('k') | content/browser/in_process_webkit/indexed_db_context.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_CONTEXT_H_ 5 #ifndef CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CONTEXT_H_
6 #define CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CONTEXT_H_ 6 #define CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CONTEXT_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/file_path.h" 10 #include "base/file_path.h"
11 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
12 #include "base/memory/scoped_ptr.h" 12 #include "base/memory/scoped_ptr.h"
13 #include "content/browser/browser_thread.h"
13 14
14 class GURL; 15 class GURL;
15 class FilePath; 16 class FilePath;
16 class WebKitContext; 17 class WebKitContext;
17 18
18 namespace WebKit { 19 namespace WebKit {
19 class WebIDBFactory; 20 class WebIDBFactory;
20 } 21 }
21 22
23 namespace base {
24 class MessageLoopProxy;
25 }
26
22 namespace quota { 27 namespace quota {
28 class QuotaManagerProxy;
23 class SpecialStoragePolicy; 29 class SpecialStoragePolicy;
24 } 30 }
25 31
26 class IndexedDBContext { 32 class IndexedDBContext :
33 public base::RefCountedThreadSafe<IndexedDBContext,
34 BrowserThread::DeleteOnWebKitThread> {
27 public: 35 public:
28 IndexedDBContext(WebKitContext* webkit_context, 36 IndexedDBContext(WebKitContext* webkit_context,
29 quota::SpecialStoragePolicy* special_storage_policy); 37 quota::SpecialStoragePolicy* special_storage_policy,
38 quota::QuotaManagerProxy* quota_manager_proxy,
39 base::MessageLoopProxy* webkit_thread_loop);
40
30 ~IndexedDBContext(); 41 ~IndexedDBContext();
31 42
32 WebKit::WebIDBFactory* GetIDBFactory(); 43 WebKit::WebIDBFactory* GetIDBFactory();
33 44
34 // The indexed db directory. 45 // The indexed db directory.
35 static const FilePath::CharType kIndexedDBDirectory[]; 46 static const FilePath::CharType kIndexedDBDirectory[];
36 47
37 // The indexed db file extension. 48 // The indexed db file extension.
38 static const FilePath::CharType kIndexedDBExtension[]; 49 static const FilePath::CharType kIndexedDBExtension[];
39 50
(...skipping 22 matching lines...) Expand all
62 scoped_ptr<WebKit::WebIDBFactory> idb_factory_; 73 scoped_ptr<WebKit::WebIDBFactory> idb_factory_;
63 74
64 // Path where the indexed db data is stored 75 // Path where the indexed db data is stored
65 FilePath data_path_; 76 FilePath data_path_;
66 77
67 // True if the destructor should delete its files. 78 // True if the destructor should delete its files.
68 bool clear_local_state_on_exit_; 79 bool clear_local_state_on_exit_;
69 80
70 scoped_refptr<quota::SpecialStoragePolicy> special_storage_policy_; 81 scoped_refptr<quota::SpecialStoragePolicy> special_storage_policy_;
71 82
83 scoped_refptr<quota::QuotaManagerProxy> quota_manager_proxy_;
84
72 DISALLOW_COPY_AND_ASSIGN(IndexedDBContext); 85 DISALLOW_COPY_AND_ASSIGN(IndexedDBContext);
73 }; 86 };
74 87
75 #endif // CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CONTEXT_H_ 88 #endif // CONTENT_BROWSER_IN_PROCESS_WEBKIT_INDEXED_DB_CONTEXT_H_
OLDNEW
« no previous file with comments | « chrome/test/testing_profile.cc ('k') | content/browser/in_process_webkit/indexed_db_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698