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

Side by Side Diff: content/browser/storage_partition_impl.h

Issue 1832813002: Add mojom module suffix in .mojom files in content. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address Tom's comment Created 4 years, 8 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 (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 CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_ 5 #ifndef CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_
6 #define CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_ 6 #define CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 13 matching lines...) Expand all
24 #include "content/browser/service_worker/service_worker_context_wrapper.h" 24 #include "content/browser/service_worker/service_worker_context_wrapper.h"
25 #include "content/common/content_export.h" 25 #include "content/common/content_export.h"
26 #include "content/common/storage_partition_service.mojom.h" 26 #include "content/common/storage_partition_service.mojom.h"
27 #include "content/public/browser/storage_partition.h" 27 #include "content/public/browser/storage_partition.h"
28 #include "mojo/public/cpp/bindings/binding_set.h" 28 #include "mojo/public/cpp/bindings/binding_set.h"
29 #include "storage/browser/quota/special_storage_policy.h" 29 #include "storage/browser/quota/special_storage_policy.h"
30 30
31 namespace content { 31 namespace content {
32 32
33 class StoragePartitionImpl : public StoragePartition, 33 class StoragePartitionImpl : public StoragePartition,
34 public StoragePartitionService { 34 public mojom::StoragePartitionService {
35 public: 35 public:
36 CONTENT_EXPORT ~StoragePartitionImpl() override; 36 CONTENT_EXPORT ~StoragePartitionImpl() override;
37 37
38 // Quota managed data uses a different bitmask for types than 38 // Quota managed data uses a different bitmask for types than
39 // StoragePartition uses. This method generates that mask. 39 // StoragePartition uses. This method generates that mask.
40 CONTENT_EXPORT static int GenerateQuotaClientMask(uint32_t remove_mask); 40 CONTENT_EXPORT static int GenerateQuotaClientMask(uint32_t remove_mask);
41 41
42 CONTENT_EXPORT void OverrideQuotaManagerForTesting( 42 CONTENT_EXPORT void OverrideQuotaManagerForTesting(
43 storage::QuotaManager* quota_manager); 43 storage::QuotaManager* quota_manager);
44 CONTENT_EXPORT void OverrideSpecialStoragePolicyForTesting( 44 CONTENT_EXPORT void OverrideSpecialStoragePolicyForTesting(
(...skipping 12 matching lines...) Expand all
57 CacheStorageContextImpl* GetCacheStorageContext() override; 57 CacheStorageContextImpl* GetCacheStorageContext() override;
58 ServiceWorkerContextWrapper* GetServiceWorkerContext() override; 58 ServiceWorkerContextWrapper* GetServiceWorkerContext() override;
59 GeofencingManager* GetGeofencingManager() override; 59 GeofencingManager* GetGeofencingManager() override;
60 HostZoomMap* GetHostZoomMap() override; 60 HostZoomMap* GetHostZoomMap() override;
61 HostZoomLevelContext* GetHostZoomLevelContext() override; 61 HostZoomLevelContext* GetHostZoomLevelContext() override;
62 ZoomLevelDelegate* GetZoomLevelDelegate() override; 62 ZoomLevelDelegate* GetZoomLevelDelegate() override;
63 NavigatorConnectContextImpl* GetNavigatorConnectContext() override; 63 NavigatorConnectContextImpl* GetNavigatorConnectContext() override;
64 PlatformNotificationContextImpl* GetPlatformNotificationContext() override; 64 PlatformNotificationContextImpl* GetPlatformNotificationContext() override;
65 BackgroundSyncContextImpl* GetBackgroundSyncContext() override; 65 BackgroundSyncContextImpl* GetBackgroundSyncContext() override;
66 66
67 // StoragePartitionService interface. 67 // mojom::StoragePartitionService interface.
68 void OpenLocalStorage( 68 void OpenLocalStorage(
69 const url::Origin& origin, 69 const url::Origin& origin,
70 mojo::InterfaceRequest<LevelDBWrapper> request) override; 70 mojo::InterfaceRequest<mojom::LevelDBWrapper> request) override;
71 71
72 void ClearDataForOrigin(uint32_t remove_mask, 72 void ClearDataForOrigin(uint32_t remove_mask,
73 uint32_t quota_storage_remove_mask, 73 uint32_t quota_storage_remove_mask,
74 const GURL& storage_origin, 74 const GURL& storage_origin,
75 net::URLRequestContextGetter* request_context_getter, 75 net::URLRequestContextGetter* request_context_getter,
76 const base::Closure& callback) override; 76 const base::Closure& callback) override;
77 void ClearData(uint32_t remove_mask, 77 void ClearData(uint32_t remove_mask,
78 uint32_t quota_storage_remove_mask, 78 uint32_t quota_storage_remove_mask,
79 const GURL& storage_origin, 79 const GURL& storage_origin,
80 const OriginMatcherFunction& origin_matcher, 80 const OriginMatcherFunction& origin_matcher,
81 const base::Time begin, 81 const base::Time begin,
82 const base::Time end, 82 const base::Time end,
83 const base::Closure& callback) override; 83 const base::Closure& callback) override;
84 84
85 void Flush() override; 85 void Flush() override;
86 86
87 WebRTCIdentityStore* GetWebRTCIdentityStore(); 87 WebRTCIdentityStore* GetWebRTCIdentityStore();
88 88
89 // Can return nullptr while |this| is being destroyed. 89 // Can return nullptr while |this| is being destroyed.
90 BrowserContext* browser_context() const; 90 BrowserContext* browser_context() const;
91 91
92 // Called by each renderer process once. 92 // Called by each renderer process once.
93 void Bind(mojo::InterfaceRequest<StoragePartitionService> request); 93 void Bind(mojo::InterfaceRequest<mojom::StoragePartitionService> request);
94 94
95 struct DataDeletionHelper; 95 struct DataDeletionHelper;
96 struct QuotaManagedDataDeletionHelper; 96 struct QuotaManagedDataDeletionHelper;
97 97
98 private: 98 private:
99 friend class BackgroundSyncManagerTest; 99 friend class BackgroundSyncManagerTest;
100 friend class BackgroundSyncServiceImplTest; 100 friend class BackgroundSyncServiceImplTest;
101 friend class StoragePartitionImplMap; 101 friend class StoragePartitionImplMap;
102 FRIEND_TEST_ALL_PREFIXES(StoragePartitionShaderClearTest, ClearShaderCache); 102 FRIEND_TEST_ALL_PREFIXES(StoragePartitionShaderClearTest, ClearShaderCache);
103 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, 103 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest,
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
199 scoped_refptr<CacheStorageContextImpl> cache_storage_context_; 199 scoped_refptr<CacheStorageContextImpl> cache_storage_context_;
200 scoped_refptr<ServiceWorkerContextWrapper> service_worker_context_; 200 scoped_refptr<ServiceWorkerContextWrapper> service_worker_context_;
201 scoped_refptr<WebRTCIdentityStore> webrtc_identity_store_; 201 scoped_refptr<WebRTCIdentityStore> webrtc_identity_store_;
202 scoped_refptr<storage::SpecialStoragePolicy> special_storage_policy_; 202 scoped_refptr<storage::SpecialStoragePolicy> special_storage_policy_;
203 scoped_refptr<GeofencingManager> geofencing_manager_; 203 scoped_refptr<GeofencingManager> geofencing_manager_;
204 scoped_refptr<HostZoomLevelContext> host_zoom_level_context_; 204 scoped_refptr<HostZoomLevelContext> host_zoom_level_context_;
205 scoped_refptr<NavigatorConnectContextImpl> navigator_connect_context_; 205 scoped_refptr<NavigatorConnectContextImpl> navigator_connect_context_;
206 scoped_refptr<PlatformNotificationContextImpl> platform_notification_context_; 206 scoped_refptr<PlatformNotificationContextImpl> platform_notification_context_;
207 scoped_refptr<BackgroundSyncContextImpl> background_sync_context_; 207 scoped_refptr<BackgroundSyncContextImpl> background_sync_context_;
208 208
209 mojo::BindingSet<StoragePartitionService> bindings_; 209 mojo::BindingSet<mojom::StoragePartitionService> bindings_;
210 210
211 // Raw pointer that should always be valid. The BrowserContext owns the 211 // Raw pointer that should always be valid. The BrowserContext owns the
212 // StoragePartitionImplMap which then owns StoragePartitionImpl. When the 212 // StoragePartitionImplMap which then owns StoragePartitionImpl. When the
213 // BrowserContext is destroyed, |this| will be destroyed too. 213 // BrowserContext is destroyed, |this| will be destroyed too.
214 BrowserContext* browser_context_; 214 BrowserContext* browser_context_;
215 215
216 DISALLOW_COPY_AND_ASSIGN(StoragePartitionImpl); 216 DISALLOW_COPY_AND_ASSIGN(StoragePartitionImpl);
217 }; 217 };
218 218
219 } // namespace content 219 } // namespace content
220 220
221 #endif // CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_ 221 #endif // CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/service_worker/service_worker_version_unittest.cc ('k') | content/browser/storage_partition_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698