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 ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ | 5 #ifndef ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ |
6 #define ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ | 6 #define ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "android_webview/browser/aw_download_manager_delegate.h" | 10 #include "android_webview/browser/aw_download_manager_delegate.h" |
(...skipping 14 matching lines...) Expand all Loading... |
25 class VisitedLinkMaster; | 25 class VisitedLinkMaster; |
26 } // namespace components | 26 } // namespace components |
27 | 27 |
28 namespace content { | 28 namespace content { |
29 class ResourceContext; | 29 class ResourceContext; |
30 class WebContents; | 30 class WebContents; |
31 } // namespace content | 31 } // namespace content |
32 | 32 |
33 namespace android_webview { | 33 namespace android_webview { |
34 | 34 |
| 35 class AwFormDatabaseService; |
| 36 class AwQuotaManagerBridge; |
35 class AwURLRequestContextGetter; | 37 class AwURLRequestContextGetter; |
36 class AwQuotaManagerBridge; | |
37 class JniDependencyFactory; | 38 class JniDependencyFactory; |
38 | 39 |
39 class AwBrowserContext : public content::BrowserContext, | 40 class AwBrowserContext : public content::BrowserContext, |
40 public components::VisitedLinkDelegate { | 41 public components::VisitedLinkDelegate { |
41 public: | 42 public: |
42 | 43 |
43 AwBrowserContext(const base::FilePath path, | 44 AwBrowserContext(const base::FilePath path, |
44 JniDependencyFactory* native_factory); | 45 JniDependencyFactory* native_factory); |
45 virtual ~AwBrowserContext(); | 46 virtual ~AwBrowserContext(); |
46 | 47 |
(...skipping 13 matching lines...) Expand all Loading... |
60 | 61 |
61 net::URLRequestContextGetter* CreateRequestContext( | 62 net::URLRequestContextGetter* CreateRequestContext( |
62 content::ProtocolHandlerMap* protocol_handlers); | 63 content::ProtocolHandlerMap* protocol_handlers); |
63 net::URLRequestContextGetter* CreateRequestContextForStoragePartition( | 64 net::URLRequestContextGetter* CreateRequestContextForStoragePartition( |
64 const base::FilePath& partition_path, | 65 const base::FilePath& partition_path, |
65 bool in_memory, | 66 bool in_memory, |
66 content::ProtocolHandlerMap* protocol_handlers); | 67 content::ProtocolHandlerMap* protocol_handlers); |
67 | 68 |
68 AwQuotaManagerBridge* GetQuotaManagerBridge(); | 69 AwQuotaManagerBridge* GetQuotaManagerBridge(); |
69 | 70 |
| 71 AwFormDatabaseService* GetFormDatabaseService(); |
| 72 |
70 // content::BrowserContext implementation. | 73 // content::BrowserContext implementation. |
71 virtual base::FilePath GetPath() OVERRIDE; | 74 virtual base::FilePath GetPath() OVERRIDE; |
72 virtual bool IsOffTheRecord() const OVERRIDE; | 75 virtual bool IsOffTheRecord() const OVERRIDE; |
73 virtual net::URLRequestContextGetter* GetRequestContext() OVERRIDE; | 76 virtual net::URLRequestContextGetter* GetRequestContext() OVERRIDE; |
74 virtual net::URLRequestContextGetter* GetRequestContextForRenderProcess( | 77 virtual net::URLRequestContextGetter* GetRequestContextForRenderProcess( |
75 int renderer_child_id) OVERRIDE; | 78 int renderer_child_id) OVERRIDE; |
76 virtual net::URLRequestContextGetter* GetMediaRequestContext() OVERRIDE; | 79 virtual net::URLRequestContextGetter* GetMediaRequestContext() OVERRIDE; |
77 virtual net::URLRequestContextGetter* GetMediaRequestContextForRenderProcess( | 80 virtual net::URLRequestContextGetter* GetMediaRequestContextForRenderProcess( |
78 int renderer_child_id) OVERRIDE; | 81 int renderer_child_id) OVERRIDE; |
79 virtual net::URLRequestContextGetter* | 82 virtual net::URLRequestContextGetter* |
(...skipping 14 matching lines...) Expand all Loading... |
94 | 97 |
95 private: | 98 private: |
96 // The file path where data for this context is persisted. | 99 // The file path where data for this context is persisted. |
97 base::FilePath context_storage_path_; | 100 base::FilePath context_storage_path_; |
98 | 101 |
99 JniDependencyFactory* native_factory_; | 102 JniDependencyFactory* native_factory_; |
100 scoped_refptr<AwURLRequestContextGetter> url_request_context_getter_; | 103 scoped_refptr<AwURLRequestContextGetter> url_request_context_getter_; |
101 scoped_refptr<content::GeolocationPermissionContext> | 104 scoped_refptr<content::GeolocationPermissionContext> |
102 geolocation_permission_context_; | 105 geolocation_permission_context_; |
103 scoped_ptr<AwQuotaManagerBridge> quota_manager_bridge_; | 106 scoped_ptr<AwQuotaManagerBridge> quota_manager_bridge_; |
| 107 scoped_ptr<AwFormDatabaseService> form_database_service_; |
104 | 108 |
105 AwDownloadManagerDelegate download_manager_delegate_; | 109 AwDownloadManagerDelegate download_manager_delegate_; |
106 | 110 |
107 scoped_ptr<components::VisitedLinkMaster> visitedlink_master_; | 111 scoped_ptr<components::VisitedLinkMaster> visitedlink_master_; |
108 scoped_ptr<content::ResourceContext> resource_context_; | 112 scoped_ptr<content::ResourceContext> resource_context_; |
109 | 113 |
110 DISALLOW_COPY_AND_ASSIGN(AwBrowserContext); | 114 DISALLOW_COPY_AND_ASSIGN(AwBrowserContext); |
111 }; | 115 }; |
112 | 116 |
113 } // namespace android_webview | 117 } // namespace android_webview |
114 | 118 |
115 #endif // ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ | 119 #endif // ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ |
OLD | NEW |