| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ | 6 #define CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.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 "base/memory/weak_ptr.h" | 13 #include "base/memory/weak_ptr.h" |
| 14 #include "chrome/browser/policy/chrome_browser_policy_connector.h" | 14 #include "chrome/browser/policy/chrome_browser_policy_connector.h" |
| 15 #include "components/policy/core/common/cloud/cloud_policy_constants.h" | 15 #include "components/policy/core/common/cloud/cloud_policy_constants.h" |
| 16 | 16 |
| 17 class PrefRegistrySimple; | 17 class PrefRegistrySimple; |
| 18 class PrefService; | 18 class PrefService; |
| 19 | 19 |
| 20 namespace net { | 20 namespace net { |
| 21 class URLRequestContextGetter; | 21 class URLRequestContextGetter; |
| 22 } | 22 } |
| 23 | 23 |
| 24 namespace policy { | 24 namespace policy { |
| 25 | 25 |
| 26 class AppPackUpdater; | 26 class ConsumerEnrollmentHandler; |
| 27 class ConsumerManagementService; | 27 class ConsumerManagementService; |
| 28 class DeviceCloudPolicyInitializer; | 28 class DeviceCloudPolicyInitializer; |
| 29 class DeviceCloudPolicyInvalidator; | 29 class DeviceCloudPolicyInvalidator; |
| 30 class DeviceCloudPolicyManagerChromeOS; | 30 class DeviceCloudPolicyManagerChromeOS; |
| 31 class DeviceLocalAccountPolicyService; | 31 class DeviceLocalAccountPolicyService; |
| 32 class DeviceManagementService; | 32 class DeviceManagementService; |
| 33 class EnterpriseInstallAttributes; | 33 class EnterpriseInstallAttributes; |
| 34 class NetworkConfigurationUpdater; | 34 class NetworkConfigurationUpdater; |
| 35 class ProxyPolicyProvider; | 35 class ProxyPolicyProvider; |
| 36 class ServerBackedStateKeysBroker; | 36 class ServerBackedStateKeysBroker; |
| (...skipping 27 matching lines...) Expand all Loading... |
| 64 // Returns the device mode. For ChromeOS this function will return the mode | 64 // Returns the device mode. For ChromeOS this function will return the mode |
| 65 // stored in the lockbox, or DEVICE_MODE_CONSUMER if the lockbox has been | 65 // stored in the lockbox, or DEVICE_MODE_CONSUMER if the lockbox has been |
| 66 // locked empty, or DEVICE_MODE_UNKNOWN if the device has not been owned yet. | 66 // locked empty, or DEVICE_MODE_UNKNOWN if the device has not been owned yet. |
| 67 // For other OSes the function will always return DEVICE_MODE_CONSUMER. | 67 // For other OSes the function will always return DEVICE_MODE_CONSUMER. |
| 68 DeviceMode GetDeviceMode(); | 68 DeviceMode GetDeviceMode(); |
| 69 | 69 |
| 70 // Works out the user affiliation by checking the given |user_name| against | 70 // Works out the user affiliation by checking the given |user_name| against |
| 71 // the installation attributes. | 71 // the installation attributes. |
| 72 UserAffiliation GetUserAffiliation(const std::string& user_name); | 72 UserAffiliation GetUserAffiliation(const std::string& user_name); |
| 73 | 73 |
| 74 AppPackUpdater* GetAppPackUpdater(); | |
| 75 | |
| 76 DeviceCloudPolicyManagerChromeOS* GetDeviceCloudPolicyManager() { | 74 DeviceCloudPolicyManagerChromeOS* GetDeviceCloudPolicyManager() { |
| 77 return device_cloud_policy_manager_; | 75 return device_cloud_policy_manager_; |
| 78 } | 76 } |
| 79 | 77 |
| 80 DeviceCloudPolicyInitializer* GetDeviceCloudPolicyInitializer() { | 78 DeviceCloudPolicyInitializer* GetDeviceCloudPolicyInitializer() { |
| 81 return device_cloud_policy_initializer_.get(); | 79 return device_cloud_policy_initializer_.get(); |
| 82 } | 80 } |
| 83 | 81 |
| 84 DeviceLocalAccountPolicyService* GetDeviceLocalAccountPolicyService() { | 82 DeviceLocalAccountPolicyService* GetDeviceLocalAccountPolicyService() { |
| 85 return device_local_account_policy_service_.get(); | 83 return device_local_account_policy_service_.get(); |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 148 scoped_ptr<DeviceCloudPolicyInvalidator> device_cloud_policy_invalidator_; | 146 scoped_ptr<DeviceCloudPolicyInvalidator> device_cloud_policy_invalidator_; |
| 149 | 147 |
| 150 // This policy provider is used on Chrome OS to feed user policy into the | 148 // This policy provider is used on Chrome OS to feed user policy into the |
| 151 // global PolicyService instance. This works by installing the cloud policy | 149 // global PolicyService instance. This works by installing the cloud policy |
| 152 // provider of the primary profile as the delegate of the ProxyPolicyProvider, | 150 // provider of the primary profile as the delegate of the ProxyPolicyProvider, |
| 153 // after login. | 151 // after login. |
| 154 // The provider is owned by the base class; this field is just a typed weak | 152 // The provider is owned by the base class; this field is just a typed weak |
| 155 // pointer to get to the ProxyPolicyProvider at SetUserPolicyDelegate(). | 153 // pointer to get to the ProxyPolicyProvider at SetUserPolicyDelegate(). |
| 156 ProxyPolicyProvider* global_user_cloud_policy_provider_; | 154 ProxyPolicyProvider* global_user_cloud_policy_provider_; |
| 157 | 155 |
| 158 scoped_ptr<AppPackUpdater> app_pack_updater_; | |
| 159 scoped_ptr<NetworkConfigurationUpdater> network_configuration_updater_; | 156 scoped_ptr<NetworkConfigurationUpdater> network_configuration_updater_; |
| 160 | 157 |
| 161 base::WeakPtrFactory<BrowserPolicyConnectorChromeOS> weak_ptr_factory_; | 158 base::WeakPtrFactory<BrowserPolicyConnectorChromeOS> weak_ptr_factory_; |
| 162 | 159 |
| 163 DISALLOW_COPY_AND_ASSIGN(BrowserPolicyConnectorChromeOS); | 160 DISALLOW_COPY_AND_ASSIGN(BrowserPolicyConnectorChromeOS); |
| 164 }; | 161 }; |
| 165 | 162 |
| 166 } // namespace policy | 163 } // namespace policy |
| 167 | 164 |
| 168 #endif // CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ | 165 #endif // CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ |
| OLD | NEW |