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 CHROME_BROWSER_EXTENSIONS_EXTENSION_SPECIAL_STORAGE_POLICY_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_SPECIAL_STORAGE_POLICY_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_SPECIAL_STORAGE_POLICY_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_SPECIAL_STORAGE_POLICY_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 18 matching lines...) Expand all Loading... |
29 class ExtensionSpecialStoragePolicy : public storage::SpecialStoragePolicy { | 29 class ExtensionSpecialStoragePolicy : public storage::SpecialStoragePolicy { |
30 public: | 30 public: |
31 explicit ExtensionSpecialStoragePolicy(CookieSettings* cookie_settings); | 31 explicit ExtensionSpecialStoragePolicy(CookieSettings* cookie_settings); |
32 | 32 |
33 // storage::SpecialStoragePolicy methods used by storage subsystems and the | 33 // storage::SpecialStoragePolicy methods used by storage subsystems and the |
34 // browsing data remover. These methods are safe to call on any thread. | 34 // browsing data remover. These methods are safe to call on any thread. |
35 bool IsStorageProtected(const GURL& origin) override; | 35 bool IsStorageProtected(const GURL& origin) override; |
36 bool IsStorageUnlimited(const GURL& origin) override; | 36 bool IsStorageUnlimited(const GURL& origin) override; |
37 bool IsStorageSessionOnly(const GURL& origin) override; | 37 bool IsStorageSessionOnly(const GURL& origin) override; |
38 bool CanQueryDiskSize(const GURL& origin) override; | 38 bool CanQueryDiskSize(const GURL& origin) override; |
39 bool IsFileHandler(const std::string& extension_id) override; | |
40 bool HasIsolatedStorage(const GURL& origin) override; | 39 bool HasIsolatedStorage(const GURL& origin) override; |
41 bool HasSessionOnlyOrigins() override; | 40 bool HasSessionOnlyOrigins() override; |
42 | 41 |
43 // Methods used by the ExtensionService to populate this class. | 42 // Methods used by the ExtensionService to populate this class. |
44 void GrantRightsForExtension(const extensions::Extension* extension, | 43 void GrantRightsForExtension(const extensions::Extension* extension, |
45 content::BrowserContext* browser_context); | 44 content::BrowserContext* browser_context); |
46 void RevokeRightsForExtension(const extensions::Extension* extension); | 45 void RevokeRightsForExtension(const extensions::Extension* extension); |
47 void RevokeRightsForAllExtensions(); | 46 void RevokeRightsForAllExtensions(); |
48 | 47 |
49 // Decides whether the storage for |extension|'s web extent needs protection. | 48 // Decides whether the storage for |extension|'s web extent needs protection. |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 SpecialCollection protected_apps_; | 87 SpecialCollection protected_apps_; |
89 SpecialCollection installed_apps_; | 88 SpecialCollection installed_apps_; |
90 SpecialCollection unlimited_extensions_; | 89 SpecialCollection unlimited_extensions_; |
91 SpecialCollection file_handler_extensions_; | 90 SpecialCollection file_handler_extensions_; |
92 SpecialCollection isolated_extensions_; | 91 SpecialCollection isolated_extensions_; |
93 SpecialCollection content_capabilities_unlimited_extensions_; | 92 SpecialCollection content_capabilities_unlimited_extensions_; |
94 scoped_refptr<CookieSettings> cookie_settings_; | 93 scoped_refptr<CookieSettings> cookie_settings_; |
95 }; | 94 }; |
96 | 95 |
97 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_SPECIAL_STORAGE_POLICY_H_ | 96 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_SPECIAL_STORAGE_POLICY_H_ |
OLD | NEW |