| 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_DEVICE_CLOUD_POLICY_INITIALIZER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_INITIALIZER_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_INITIALIZER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_INITIALIZER_H_ |
| 7 | 7 |
| 8 #include <bitset> | 8 #include <bitset> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/callback_forward.h" | 11 #include "base/callback_forward.h" |
| 12 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
| 13 #include "base/macros.h" | 13 #include "base/macros.h" |
| 14 #include "base/memory/ref_counted.h" | 14 #include "base/memory/ref_counted.h" |
| 15 #include "base/memory/scoped_ptr.h" | 15 #include "base/memory/scoped_ptr.h" |
| 16 #include "chrome/browser/chromeos/policy/enrollment_status_chromeos.h" | 16 #include "chrome/browser/chromeos/policy/enrollment_status_chromeos.h" |
| 17 #include "chrome/browser/chromeos/policy/server_backed_state_keys_broker.h" | 17 #include "chrome/browser/chromeos/policy/server_backed_state_keys_broker.h" |
| 18 #include "components/policy/core/common/cloud/cloud_policy_client.h" | 18 #include "components/policy/core/common/cloud/cloud_policy_client.h" |
| 19 #include "components/policy/core/common/cloud/cloud_policy_constants.h" | 19 #include "components/policy/core/common/cloud/cloud_policy_constants.h" |
| 20 #include "components/policy/core/common/cloud/cloud_policy_store.h" | 20 #include "components/policy/core/common/cloud/cloud_policy_store.h" |
| 21 | 21 |
| 22 class PrefService; | 22 class PrefService; |
| 23 | 23 |
| 24 namespace base { | 24 namespace base { |
| 25 class SequencedTaskRunner; | 25 class SequencedTaskRunner; |
| 26 } | 26 } |
| 27 | 27 |
| 28 namespace chromeos { | 28 namespace chromeos { |
| 29 class DeviceSettingsService; | 29 class DeviceSettingsService; |
| 30 class OwnerSettingsServiceChromeOS; |
| 30 } | 31 } |
| 31 | 32 |
| 32 namespace policy { | 33 namespace policy { |
| 33 | 34 |
| 34 class DeviceCloudPolicyManagerChromeOS; | 35 class DeviceCloudPolicyManagerChromeOS; |
| 35 class DeviceCloudPolicyStoreChromeOS; | 36 class DeviceCloudPolicyStoreChromeOS; |
| 36 class DeviceManagementService; | 37 class DeviceManagementService; |
| 37 class EnrollmentHandlerChromeOS; | 38 class EnrollmentHandlerChromeOS; |
| 38 class EnterpriseInstallAttributes; | 39 class EnterpriseInstallAttributes; |
| 39 | 40 |
| (...skipping 25 matching lines...) Expand all Loading... |
| 65 // Starts enrollment or re-enrollment. Once the enrollment process completes, | 66 // Starts enrollment or re-enrollment. Once the enrollment process completes, |
| 66 // |enrollment_callback| is invoked and gets passed the status of the | 67 // |enrollment_callback| is invoked and gets passed the status of the |
| 67 // operation. | 68 // operation. |
| 68 // |allowed_modes| specifies acceptable DEVICE_MODE_* constants for | 69 // |allowed_modes| specifies acceptable DEVICE_MODE_* constants for |
| 69 // enrollment. | 70 // enrollment. |
| 70 // |management_mode| should be either MANAGEMENT_MODE_ENTERPRISE or | 71 // |management_mode| should be either MANAGEMENT_MODE_ENTERPRISE or |
| 71 // MANAGEMENT_MODE_CONSUMER. | 72 // MANAGEMENT_MODE_CONSUMER. |
| 72 virtual void StartEnrollment( | 73 virtual void StartEnrollment( |
| 73 ManagementMode management_mode, | 74 ManagementMode management_mode, |
| 74 DeviceManagementService* device_management_service, | 75 DeviceManagementService* device_management_service, |
| 76 chromeos::OwnerSettingsServiceChromeOS* owner_settings_service, |
| 75 const std::string& auth_token, | 77 const std::string& auth_token, |
| 76 const AllowedDeviceModes& allowed_modes, | 78 const AllowedDeviceModes& allowed_modes, |
| 77 const EnrollmentCallback& enrollment_callback); | 79 const EnrollmentCallback& enrollment_callback); |
| 78 | 80 |
| 79 // Checks whether enterprise enrollment should be a regular step during OOBE. | 81 // Checks whether enterprise enrollment should be a regular step during OOBE. |
| 80 bool ShouldAutoStartEnrollment() const; | 82 bool ShouldAutoStartEnrollment() const; |
| 81 | 83 |
| 82 // Checks whether enterprise enrollment recovery is required. | 84 // Checks whether enterprise enrollment recovery is required. |
| 83 bool ShouldRecoverEnrollment() const; | 85 bool ShouldRecoverEnrollment() const; |
| 84 | 86 |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 122 scoped_ptr<EnrollmentHandlerChromeOS> enrollment_handler_; | 124 scoped_ptr<EnrollmentHandlerChromeOS> enrollment_handler_; |
| 123 | 125 |
| 124 ServerBackedStateKeysBroker::Subscription state_keys_update_subscription_; | 126 ServerBackedStateKeysBroker::Subscription state_keys_update_subscription_; |
| 125 | 127 |
| 126 DISALLOW_COPY_AND_ASSIGN(DeviceCloudPolicyInitializer); | 128 DISALLOW_COPY_AND_ASSIGN(DeviceCloudPolicyInitializer); |
| 127 }; | 129 }; |
| 128 | 130 |
| 129 } // namespace policy | 131 } // namespace policy |
| 130 | 132 |
| 131 #endif // CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_INITIALIZER_H_ | 133 #endif // CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_INITIALIZER_H_ |
| OLD | NEW |