OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 COMPONENTS_USER_PREFS_TRACKED_DICTIONARY_HASH_STORE_CONTENTS_H_ | 5 #ifndef COMPONENTS_USER_PREFS_TRACKED_DICTIONARY_HASH_STORE_CONTENTS_H_ |
6 #define COMPONENTS_USER_PREFS_TRACKED_DICTIONARY_HASH_STORE_CONTENTS_H_ | 6 #define COMPONENTS_USER_PREFS_TRACKED_DICTIONARY_HASH_STORE_CONTENTS_H_ |
7 | 7 |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/macros.h" | 9 #include "base/macros.h" |
10 #include "components/user_prefs/tracked/hash_store_contents.h" | 10 #include "components/user_prefs/tracked/hash_store_contents.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 class DictionaryHashStoreContents : public HashStoreContents { | 24 class DictionaryHashStoreContents : public HashStoreContents { |
25 public: | 25 public: |
26 // Constructs a DictionaryHashStoreContents that reads from and writes to | 26 // Constructs a DictionaryHashStoreContents that reads from and writes to |
27 // |storage|. | 27 // |storage|. |
28 explicit DictionaryHashStoreContents(base::DictionaryValue* storage); | 28 explicit DictionaryHashStoreContents(base::DictionaryValue* storage); |
29 | 29 |
30 // Registers required preferences. | 30 // Registers required preferences. |
31 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); | 31 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); |
32 | 32 |
33 // HashStoreContents implementation | 33 // HashStoreContents implementation |
34 std::string hash_store_id() const override; | |
35 void Reset() override; | 34 void Reset() override; |
36 bool IsInitialized() const override; | 35 bool IsInitialized() const override; |
37 const base::DictionaryValue* GetContents() const override; | 36 const base::DictionaryValue* GetContents() const override; |
38 std::unique_ptr<MutableDictionary> GetMutableContents() override; | 37 std::unique_ptr<MutableDictionary> GetMutableContents() override; |
39 std::string GetSuperMac() const override; | 38 std::string GetSuperMac() const override; |
40 void SetSuperMac(const std::string& super_mac) override; | 39 void SetSuperMac(const std::string& super_mac) override; |
41 | 40 |
42 private: | 41 private: |
43 base::DictionaryValue* storage_; | 42 base::DictionaryValue* storage_; |
44 | 43 |
45 DISALLOW_COPY_AND_ASSIGN(DictionaryHashStoreContents); | 44 DISALLOW_COPY_AND_ASSIGN(DictionaryHashStoreContents); |
46 }; | 45 }; |
47 | 46 |
48 #endif // COMPONENTS_USER_PREFS_TRACKED_DICTIONARY_HASH_STORE_CONTENTS_H_ | 47 #endif // COMPONENTS_USER_PREFS_TRACKED_DICTIONARY_HASH_STORE_CONTENTS_H_ |
OLD | NEW |