OLD | NEW |
---|---|
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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_STANDARD_MANAGEMENT_POLICY_PROVIDER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_STANDARD_MANAGEMENT_POLICY_PROVIDER_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_STANDARD_MANAGEMENT_POLICY_PROVIDER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_STANDARD_MANAGEMENT_POLICY_PROVIDER_H_ |
7 | 7 |
8 #include <string> | |
Joao da Silva
2014/11/17 16:17:41
#include "base/strings/string16.h"
binjin
2014/11/18 13:25:55
Done.
| |
9 | |
8 #include "extensions/browser/management_policy.h" | 10 #include "extensions/browser/management_policy.h" |
9 | 11 |
10 namespace extensions { | 12 namespace extensions { |
11 | 13 |
12 class Blacklist; | 14 class Blacklist; |
13 class Extension; | 15 class Extension; |
14 class ExtensionManagement; | 16 class ExtensionManagement; |
15 | 17 |
16 // The standard management policy provider, which takes into account the | 18 // The standard management policy provider, which takes into account the |
17 // extension black/whitelists and admin black/whitelists. | 19 // extension black/whitelists and admin black/whitelists. |
18 class StandardManagementPolicyProvider : public ManagementPolicy::Provider { | 20 class StandardManagementPolicyProvider : public ManagementPolicy::Provider { |
19 public: | 21 public: |
20 explicit StandardManagementPolicyProvider( | 22 explicit StandardManagementPolicyProvider( |
21 const ExtensionManagement* settings); | 23 const ExtensionManagement* settings); |
22 | 24 |
23 ~StandardManagementPolicyProvider() override; | 25 ~StandardManagementPolicyProvider() override; |
24 | 26 |
25 // ManagementPolicy::Provider implementation. | 27 // ManagementPolicy::Provider implementation. |
26 std::string GetDebugPolicyProviderName() const override; | 28 std::string GetDebugPolicyProviderName() const override; |
27 bool UserMayLoad(const Extension* extension, | 29 bool UserMayLoad(const Extension* extension, |
28 base::string16* error) const override; | 30 base::string16* error) const override; |
29 bool UserMayModifySettings(const Extension* extension, | 31 bool UserMayModifySettings(const Extension* extension, |
30 base::string16* error) const override; | 32 base::string16* error) const override; |
31 bool MustRemainEnabled(const Extension* extension, | 33 bool MustRemainEnabled(const Extension* extension, |
32 base::string16* error) const override; | 34 base::string16* error) const override; |
35 bool MustRemainDisabled(const Extension* extension, | |
36 Extension::DisableReason* reason, | |
37 base::string16* error) const override; | |
33 bool MustRemainInstalled(const Extension* extension, | 38 bool MustRemainInstalled(const Extension* extension, |
34 base::string16* error) const override; | 39 base::string16* error) const override; |
35 | 40 |
36 private: | 41 private: |
37 const ExtensionManagement* settings_; | 42 const ExtensionManagement* settings_; |
38 }; | 43 }; |
39 | 44 |
40 } // namespace extensions | 45 } // namespace extensions |
41 | 46 |
42 #endif // CHROME_BROWSER_EXTENSIONS_STANDARD_MANAGEMENT_POLICY_PROVIDER_H_ | 47 #endif // CHROME_BROWSER_EXTENSIONS_STANDARD_MANAGEMENT_POLICY_PROVIDER_H_ |
OLD | NEW |