Roll src/third_party/WebKit eac3800:0237a66 (svn 202606:202607)
[chromium-blink-merge.git] / chrome / browser / prefs / chrome_pref_model_associator_client.h
blobf0b6c943d9926a3d7e2150bea0482df8cbefe85a
1 // Copyright 2015 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_CHROME_PREF_MODEL_ASSOCIATOR_CLIENT_H_
6 #define CHROME_BROWSER_PREFS_CHROME_PREF_MODEL_ASSOCIATOR_CLIENT_H_
8 #include <string>
10 #include "base/macros.h"
11 #include "components/syncable_prefs/pref_model_associator_client.h"
13 namespace base {
14 template <typename T>
15 struct DefaultSingletonTraits;
18 class ChromePrefModelAssociatorClient
19 : public syncable_prefs::PrefModelAssociatorClient {
20 public:
21 // Returns the global instance.
22 static ChromePrefModelAssociatorClient* GetInstance();
24 private:
25 friend struct base::DefaultSingletonTraits<ChromePrefModelAssociatorClient>;
27 ChromePrefModelAssociatorClient();
28 ~ChromePrefModelAssociatorClient() override;
30 // syncable_prefs::PrefModelAssociatorClient implementation.
31 bool IsMergeableListPreference(const std::string& pref_name) const override;
32 bool IsMergeableDictionaryPreference(
33 const std::string& pref_name) const override;
34 bool IsMigratedPreference(const std::string& new_pref_name,
35 std::string* old_pref_name) const override;
36 bool IsOldMigratedPreference(const std::string& old_pref_name,
37 std::string* new_pref_name) const override;
39 DISALLOW_COPY_AND_ASSIGN(ChromePrefModelAssociatorClient);
42 #endif // CHROME_BROWSER_PREFS_CHROME_PREF_MODEL_ASSOCIATOR_CLIENT_H_