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

Unified Diff: chrome/browser/prefs/pref_service_syncable_factory.h

Issue 64193003: Clean up PrefServiceBuilder (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix memory ownership bug in ProxyPolicyTest Created 7 years, 1 month 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/prefs/pref_service_syncable_factory.h
diff --git a/chrome/browser/prefs/pref_service_syncable_builder.h b/chrome/browser/prefs/pref_service_syncable_factory.h
similarity index 45%
rename from chrome/browser/prefs/pref_service_syncable_builder.h
rename to chrome/browser/prefs/pref_service_syncable_factory.h
index df0e53d0a7bf289c042ee37894b4f4f7279966b6..698b9248d451fee063c2bec157b665524b2a0e95 100644
--- a/chrome/browser/prefs/pref_service_syncable_builder.h
+++ b/chrome/browser/prefs/pref_service_syncable_factory.h
@@ -2,10 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_BUILDER_H_
-#define CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_BUILDER_H_
+#ifndef CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_FACTORY_H_
+#define CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_FACTORY_H_
-#include "base/prefs/pref_service_builder.h"
+#include "base/prefs/pref_service_factory.h"
class CommandLine;
class PrefServiceSyncable;
@@ -18,30 +18,28 @@ namespace user_prefs {
class PrefRegistrySyncable;
}
-// A PrefServiceBuilder that also knows how to build a
+// A PrefServiceFactory that also knows how to build a
// PrefServiceSyncable, and may know about Chrome concepts such as
// PolicyService.
-class PrefServiceSyncableBuilder : public PrefServiceBuilder {
+class PrefServiceSyncableFactory : public base::PrefServiceFactory {
public:
- PrefServiceSyncableBuilder();
- virtual ~PrefServiceSyncableBuilder();
+ PrefServiceSyncableFactory();
+ virtual ~PrefServiceSyncableFactory();
#if defined(ENABLE_CONFIGURATION_POLICY)
// Set up policy pref stores using the given policy service.
- PrefServiceSyncableBuilder& WithManagedPolicies(
- policy::PolicyService* service);
- PrefServiceSyncableBuilder& WithRecommendedPolicies(
- policy::PolicyService* service);
+ void SetManagedPolicies(policy::PolicyService* service);
+ void SetRecommendedPolicies(policy::PolicyService* service);
#endif
// Specifies to use an actual command-line backed command-line pref store.
- PrefServiceSyncableBuilder& WithCommandLine(CommandLine* command_line);
+ void SetCommandLine(CommandLine* command_line);
- virtual PrefServiceSyncable* CreateSyncable(
+ scoped_ptr<PrefServiceSyncable> CreateSyncable(
user_prefs::PrefRegistrySyncable* registry);
private:
- DISALLOW_COPY_AND_ASSIGN(PrefServiceSyncableBuilder);
+ DISALLOW_COPY_AND_ASSIGN(PrefServiceSyncableFactory);
};
-#endif // CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_BUILDER_H_
+#endif // CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_FACTORY_H_
« no previous file with comments | « chrome/browser/prefs/pref_service_syncable_builder.cc ('k') | chrome/browser/prefs/pref_service_syncable_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698