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

Side by Side Diff: chrome/browser/chromeos/settings/device_settings_provider.h

Issue 502993003: DeviceSettingsProvider::Decode*() methods are moved out to the anonymous namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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
« no previous file with comments | « no previous file | chrome/browser/chromeos/settings/device_settings_provider.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_
6 #define CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_ 6 #define CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 // Populates in-memory cache from the local_state cache that is used to store 62 // Populates in-memory cache from the local_state cache that is used to store
63 // device settings before the device is owned and to speed up policy 63 // device settings before the device is owned and to speed up policy
64 // availability before the policy blob is fetched on boot. 64 // availability before the policy blob is fetched on boot.
65 void RetrieveCachedData(); 65 void RetrieveCachedData();
66 66
67 // Stores a value from the |pending_changes_| queue in the device settings. 67 // Stores a value from the |pending_changes_| queue in the device settings.
68 // If the device is not owned yet the data ends up only in the local_state 68 // If the device is not owned yet the data ends up only in the local_state
69 // cache and is serialized once ownership is acquired. 69 // cache and is serialized once ownership is acquired.
70 void SetInPolicy(); 70 void SetInPolicy();
71 71
72 // Decode the various groups of policies.
73 void DecodeLoginPolicies(
74 const enterprise_management::ChromeDeviceSettingsProto& policy,
75 PrefValueMap* new_values_cache) const;
76 void DecodeKioskPolicies(
77 const enterprise_management::ChromeDeviceSettingsProto& policy,
78 PrefValueMap* new_values_cache) const;
79 void DecodeNetworkPolicies(
80 const enterprise_management::ChromeDeviceSettingsProto& policy,
81 PrefValueMap* new_values_cache) const;
82 void DecodeAutoUpdatePolicies(
83 const enterprise_management::ChromeDeviceSettingsProto& policy,
84 PrefValueMap* new_values_cache) const;
85 void DecodeReportingPolicies(
86 const enterprise_management::ChromeDeviceSettingsProto& policy,
87 PrefValueMap* new_values_cache) const;
88 void DecodeGenericPolicies(
89 const enterprise_management::ChromeDeviceSettingsProto& policy,
90 PrefValueMap* new_values_cache) const;
91
92 // Parses the policy data and fills in |values_cache_|. 72 // Parses the policy data and fills in |values_cache_|.
93 void UpdateValuesCache( 73 void UpdateValuesCache(
94 const enterprise_management::PolicyData& policy_data, 74 const enterprise_management::PolicyData& policy_data,
95 const enterprise_management::ChromeDeviceSettingsProto& settings, 75 const enterprise_management::ChromeDeviceSettingsProto& settings,
96 TrustedStatus trusted_status); 76 TrustedStatus trusted_status);
97 77
98 // Applies the metrics policy and if not set migrates the legacy file. 78 // Applies the metrics policy and if not set migrates the legacy file.
99 void ApplyMetricsSetting(bool use_file, bool new_value); 79 void ApplyMetricsSetting(bool use_file, bool new_value);
100 80
101 // Applies the data roaming policy. 81 // Applies the data roaming policy.
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 InitializationTestUnowned); 149 InitializationTestUnowned);
170 FRIEND_TEST_ALL_PREFIXES(DeviceSettingsProviderTest, 150 FRIEND_TEST_ALL_PREFIXES(DeviceSettingsProviderTest,
171 PolicyFailedPermanentlyNotification); 151 PolicyFailedPermanentlyNotification);
172 FRIEND_TEST_ALL_PREFIXES(DeviceSettingsProviderTest, PolicyLoadNotification); 152 FRIEND_TEST_ALL_PREFIXES(DeviceSettingsProviderTest, PolicyLoadNotification);
173 DISALLOW_COPY_AND_ASSIGN(DeviceSettingsProvider); 153 DISALLOW_COPY_AND_ASSIGN(DeviceSettingsProvider);
174 }; 154 };
175 155
176 } // namespace chromeos 156 } // namespace chromeos
177 157
178 #endif // CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_ 158 #endif // CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/settings/device_settings_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698