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

Unified Diff: chrome/browser/policy/config_dir_policy_provider.h

Issue 5562002: Refactor FileBasedPolicyProvider, introduce AsynchronousPolicyProvider. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge with TOT Created 10 years 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/policy/config_dir_policy_provider.h
diff --git a/chrome/browser/policy/config_dir_policy_provider.h b/chrome/browser/policy/config_dir_policy_provider.h
index 60965135099cef13c6db1a68a8f19ea21a1b6be8..3647489b04650cfb2dd509b54d2937ac01c0b35f 100644
--- a/chrome/browser/policy/config_dir_policy_provider.h
+++ b/chrome/browser/policy/config_dir_policy_provider.h
@@ -10,23 +10,6 @@
namespace policy {
-// A policy loader implementation backed by a set of files in a given directory.
-// The files should contain JSON-formatted policy settings. They are merged
-// together and the result is returned via the PolicyLoader interface. The files
-// are consulted in lexicographic file name order, so the last value read takes
-// precedence in case of preference key collisions.
-class ConfigDirPolicyLoader : public FileBasedPolicyProvider::Delegate {
- public:
- explicit ConfigDirPolicyLoader(const FilePath& config_dir);
-
- // FileBasedPolicyLoader::Delegate implementation.
- virtual DictionaryValue* Load();
- virtual base::Time GetLastModification();
-
- private:
- DISALLOW_COPY_AND_ASSIGN(ConfigDirPolicyLoader);
-};
-
// Policy provider backed by JSON files in a configuration directory.
class ConfigDirPolicyProvider : public FileBasedPolicyProvider {
public:
@@ -38,6 +21,24 @@ class ConfigDirPolicyProvider : public FileBasedPolicyProvider {
DISALLOW_COPY_AND_ASSIGN(ConfigDirPolicyProvider);
};
+// A provider delegate implementation backed by a set of files in a given
+// directory. The files should contain JSON-formatted policy settings. They are
+// merged together and the result is returned via the ProviderDelegate
+// interface. The files are consulted in lexicographic file name order, so the
+// last value read takes precedence in case of preference key collisions.
+class ConfigDirPolicyProviderDelegate
+ : public FileBasedPolicyProvider::ProviderDelegate {
+ public:
+ explicit ConfigDirPolicyProviderDelegate(const FilePath& config_dir);
+
+ // FileBasedPolicyProvider::ProviderDelegate implementation.
+ virtual DictionaryValue* Load();
+ virtual base::Time GetLastModification();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(ConfigDirPolicyProviderDelegate);
+};
+
} // namespace policy
#endif // CHROME_BROWSER_POLICY_CONFIG_DIR_POLICY_PROVIDER_H_
« no previous file with comments | « chrome/browser/policy/asynchronous_policy_test_base.h ('k') | chrome/browser/policy/config_dir_policy_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698