Disable view source for Developer Tools.
[chromium-blink-merge.git] / chrome / browser / prefs / pref_service_syncable_factory.h
blob715244efb1ea905ab3f3d5914ecb52f26da60c37
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_FACTORY_H_
6 #define CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_FACTORY_H_
8 #include "base/prefs/pref_service_factory.h"
10 class CommandLine;
11 class PrefServiceSyncable;
13 namespace policy {
14 class PolicyService;
17 namespace user_prefs {
18 class PrefRegistrySyncable;
21 // A PrefServiceFactory that also knows how to build a
22 // PrefServiceSyncable, and may know about Chrome concepts such as
23 // PolicyService.
24 class PrefServiceSyncableFactory : public base::PrefServiceFactory {
25 public:
26 PrefServiceSyncableFactory();
27 virtual ~PrefServiceSyncableFactory();
29 #if defined(ENABLE_CONFIGURATION_POLICY)
30 // Set up policy pref stores using the given policy service.
31 void SetManagedPolicies(policy::PolicyService* service);
32 void SetRecommendedPolicies(policy::PolicyService* service);
33 #endif
35 // Specifies to use an actual command-line backed command-line pref store.
36 void SetCommandLine(CommandLine* command_line);
38 scoped_ptr<PrefServiceSyncable> CreateSyncable(
39 user_prefs::PrefRegistrySyncable* registry);
41 private:
42 DISALLOW_COPY_AND_ASSIGN(PrefServiceSyncableFactory);
45 #endif // CHROME_BROWSER_PREFS_PREF_SERVICE_SYNCABLE_FACTORY_H_