Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_PREFS_TRACKED_TRACKED_ATOMIC_PREFERENCE_H_ | |
| 6 #define CHROME_BROWSER_PREFS_TRACKED_TRACKED_ATOMIC_PREFERENCE_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 #include "chrome/browser/prefs/pref_hash_filter.h" | |
| 11 #include "chrome/browser/prefs/tracked/tracked_preference.h" | |
| 12 #include "chrome/browser/prefs/tracked/tracked_preference_helper.h" | |
| 13 | |
| 14 // A TrackedAtomicPreference is tracked as a whole. A hash is stored for its | |
| 15 // entire value and it is entirely reset on mismatch. | |
| 16 class TrackedAtomicPreference : public TrackedPreference { | |
| 17 public: | |
| 18 TrackedAtomicPreference( | |
| 19 const std::string& pref_path, | |
| 20 size_t reporting_id, | |
| 21 size_t reporting_ids_count, | |
| 22 PrefHashFilter::EnforcementLevel enforcement_level); | |
| 23 | |
| 24 // TrackedPreference implementation. | |
| 25 virtual void OnValueChanged(const base::Value* value, | |
| 26 PrefHashStore* pref_hash_store) const OVERRIDE; | |
|
erikwright (departed)
2014/01/21 18:44:45
compiler_specific.h
gab
2014/01/21 20:51:42
Done.
| |
| 27 virtual void EnforceAndReport( | |
| 28 PrefHashStore* pref_hash_store, | |
| 29 base::DictionaryValue* pref_store_contents) const OVERRIDE; | |
| 30 | |
| 31 private: | |
| 32 const std::string pref_path_; | |
| 33 const TrackedPreferenceHelper helper_; | |
| 34 | |
| 35 DISALLOW_COPY_AND_ASSIGN(TrackedAtomicPreference); | |
|
erikwright (departed)
2014/01/21 18:44:45
macros.h
gab
2014/01/21 20:51:42
Done.
| |
| 36 }; | |
| 37 | |
| 38 #endif // CHROME_BROWSER_PREFS_TRACKED_TRACKED_ATOMIC_PREFERENCE_H_ | |
| OLD | NEW |