| OLD | NEW |
| 1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2016 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_PREFS_IN_MEMORY_PREF_STORE_H_ | 5 #ifndef COMPONENTS_PREFS_IN_MEMORY_PREF_STORE_H_ |
| 6 #define COMPONENTS_PREFS_IN_MEMORY_PREF_STORE_H_ | 6 #define COMPONENTS_PREFS_IN_MEMORY_PREF_STORE_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 30 matching lines...) Expand all Loading... |
| 41 void SetValueSilently(const std::string& key, | 41 void SetValueSilently(const std::string& key, |
| 42 std::unique_ptr<base::Value> value, | 42 std::unique_ptr<base::Value> value, |
| 43 uint32_t flags) override; | 43 uint32_t flags) override; |
| 44 void RemoveValue(const std::string& key, uint32_t flags) override; | 44 void RemoveValue(const std::string& key, uint32_t flags) override; |
| 45 bool ReadOnly() const override; | 45 bool ReadOnly() const override; |
| 46 PrefReadError GetReadError() const override; | 46 PrefReadError GetReadError() const override; |
| 47 PersistentPrefStore::PrefReadError ReadPrefs() override; | 47 PersistentPrefStore::PrefReadError ReadPrefs() override; |
| 48 void ReadPrefsAsync(ReadErrorDelegate* error_delegate) override {} | 48 void ReadPrefsAsync(ReadErrorDelegate* error_delegate) override {} |
| 49 void SchedulePendingLossyWrites() override {} | 49 void SchedulePendingLossyWrites() override {} |
| 50 void ClearMutableValues() override {} | 50 void ClearMutableValues() override {} |
| 51 void OnStoreDeletionFromDisk() override {} |
| 51 | 52 |
| 52 protected: | 53 protected: |
| 53 ~InMemoryPrefStore() override; | 54 ~InMemoryPrefStore() override; |
| 54 | 55 |
| 55 private: | 56 private: |
| 56 // Stores the preference values. | 57 // Stores the preference values. |
| 57 PrefValueMap prefs_; | 58 PrefValueMap prefs_; |
| 58 | 59 |
| 59 base::ObserverList<PrefStore::Observer, true> observers_; | 60 base::ObserverList<PrefStore::Observer, true> observers_; |
| 60 | 61 |
| 61 DISALLOW_COPY_AND_ASSIGN(InMemoryPrefStore); | 62 DISALLOW_COPY_AND_ASSIGN(InMemoryPrefStore); |
| 62 }; | 63 }; |
| 63 | 64 |
| 64 #endif // COMPONENTS_PREFS_IN_MEMORY_PREF_STORE_H_ | 65 #endif // COMPONENTS_PREFS_IN_MEMORY_PREF_STORE_H_ |
| OLD | NEW |